-
-
Save intenzemotion/02961f50b4ad4ffe46e91829ad729a73 to your computer and use it in GitHub Desktop.
| # This script must be run as Administrator to update some shortcut paths. Checking it first... | |
| $IsAdmin = ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole( | |
| [Security.Principal.WindowsBuiltInRole]::Administrator | |
| ) | |
| if (-not $IsAdmin) { | |
| Write-Host "Not running as Administrator. Some shortcuts may fail to update." -ForegroundColor Yellow | |
| Write-Host "" | |
| } | |
| # This is your Edge path, it should be installed here (if you're on Stable channel). | |
| $EdgePaths = "${env:ProgramFiles(x86)}\Microsoft\Edge\Application\msedge.exe" | |
| do { | |
| Write-Host "1. Old workaround (msFeatureGroupNewLookAndFeelHoldout)" | |
| Write-Host "2. New workaround (msForceNoRoundedCornerAndMargin)" | |
| Write-Host "3. Restore to default" | |
| $Choice = Read-Host "`nEnter choice" | |
| if ($Choice -eq "1") { | |
| # msFeatureGroupNewLookAndFeelHoldout is an older/broader workaround revert that ugly rounded corner. | |
| # msShowSignInIndicator is to hide the red dot on the profile icon if you wish to not sign in. | |
| $Options = '--disable-features="msShowSignInIndicator,msFeatureGroupNewLookAndFeelHoldout"' | |
| } | |
| elseif ($Choice -eq "2") { | |
| # msForceNoRoundedCornerAndMargin is a newer option for removing rounded corners. | |
| # Use this instead if msFeatureGroupNewLookAndFeelHoldout stops working or affects other UI. | |
| $Options = '--enable-features="msForceNoRoundedCornerAndMargin" --disable-features="msShowSignInIndicator"' | |
| } | |
| elseif ($Choice -eq "3") { | |
| # Restore default shortcut behavior by removing all arguments. | |
| $Options = '' | |
| } | |
| else { | |
| Write-Host "Invalid choice. Please try again.`n" -ForegroundColor Red | |
| } | |
| } until ($Choice -in @("1", "2", "3")) | |
| # Use WScript (a script host) to modify shortcuts | |
| $Shell = New-Object -ComObject WScript.Shell | |
| # This is your Edge possible shortcut paths. | |
| # If you have shortcuts placed anywhere else, put them in this list as well. | |
| $ShortcutPaths = @( | |
| "$env:Public\Desktop\Microsoft Edge.lnk", | |
| "$env:UserProfile\Desktop\Microsoft Edge.lnk", | |
| "$env:ProgramData\Microsoft\Windows\Start Menu\Programs\Microsoft Edge.lnk", | |
| "$env:AppData\Microsoft\Windows\Start Menu\Programs\Microsoft Edge.lnk", | |
| "$env:AppData\Microsoft\Internet Explorer\Quick Launch\Microsoft Edge.lnk", | |
| "$env:AppData\Microsoft\Internet Explorer\Quick Launch\User Pinned\StartMenu\Microsoft Edge.lnk", | |
| "$env:AppData\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Microsoft Edge.lnk" | |
| ) | |
| foreach ($ShortcutPath in $ShortcutPaths) { | |
| if (Test-Path -LiteralPath $ShortcutPath) { | |
| try { | |
| $Shortcut = $Shell.CreateShortcut($ShortcutPath) | |
| $Shortcut.TargetPath = $EdgePaths | |
| $Shortcut.Arguments = $Options | |
| $Shortcut.WorkingDirectory = Split-Path $EdgePaths -Parent | |
| $Shortcut.IconLocation = "$EdgePaths,0" | |
| $Shortcut.Save() | |
| Write-Host "Recreated: $ShortcutPath" -ForegroundColor Green | |
| } | |
| catch { | |
| Write-Host "Failed to update: $ShortcutPath. Error: $($_.Exception.Message)" -ForegroundColor Red | |
| } | |
| } | |
| else { | |
| Write-Host "Skipped, not found: $ShortcutPath" -ForegroundColor Yellow | |
| } | |
| } | |
| Write-Host "`nPress any key to exit..." | |
| $Host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown") | Out-Null | |
| powershell -NoExit -NoLogo -Command "Set-Location -LiteralPath '$PSScriptRoot'" |
Thank you very much!
I honestly don't understand why they keep pushing this kind of unwanted UI change while at the same time claiming that users can freely customize their experience.
I actually switched from Chrome to Edge to get away from this sort of thing, and then Edge ended up forcing it as well. For now, your script solved the problem perfectly.
Thanks again for taking the time to create and share this fix.
I used Edge for my office work and Chrome for web testing. I was so mad they actually removed the rounded corner flag lol, what were they thinking?!
Btw I have experimented with a new option called msForceNoRoundedCornerAndMargin. I'll just put that as comment in the script if anybody wanted to try it out. I tested and its working perfectly.
Thank you, thank you!
(Shees Microsoft is on a an 'enshittification' streak nowadays).
For less technically inclined people finding this solution,
you can also just add the option to the Edge startup shortcut you use,
so skip creating a PowerShell script:
.
Right-click on the Edge icon in the taskbar.
Then right-click again on the "Microsoft Edge" menu item.
Then select "Properties".
Find the "Trarget field, and add this literal text, separated with a space, (to only disable the borders):
--disable-features="msFeatureGroupNewLookAndFeelHoldout"
holy fck man this is diabolical on ms's part im so sick of this
Thank you!
I'm not sure if this applies to everyone, but I had to add this path "$env:AppData\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Microsoft Edge.lnk" to $ShortcutPaths because, for some weird reason, the icon pinned to the taskbar was ignoring the flag.
$ShortcutPaths = @(
"$env:Public\Desktop\Microsoft Edge.lnk",
"$env:ProgramData\Microsoft\Windows\Start Menu\Programs\Microsoft Edge.lnk",
"$env:AppData\Microsoft\Windows\Start Menu\Programs\Microsoft Edge.lnk",
"$env:AppData\Microsoft\Internet Explorer\Quick Launch\Microsoft Edge.lnk",
"$env:AppData\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Microsoft Edge.lnk"
)Cheers.
Need disable Startup Boost in edge://settings/system/manageSystem
@andersonsalas Ah yes, I totally forgot about pinned Edge. I will add that path to the script as well. Meanwhile, unpin and repin to taskbar work as well. Thanks!
@ganlvtech I haven't tested it with startup boost on. Either:
- Turn off Startup Boost as stated by @ganlvtech
- Or, sign out and in again
- Or, kill msedge.exe process (possible to do this in the script, but too destructive)
Thanks!
You are an absolute saint, thank you so much for this!
"C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe" --enable-features=msForceNoRoundedCornerAndMargin --disable-features=msOmniboxFocusRingRoundEmphasize

for anyone interested, not only does the first argument combo get us rid of rounded corners and those awful thick margins/borders, but the second one also restores the rounded rectangular omnibox (address bar), instead of the Chrome-like pill-shaped one that replaced it (this trick is three years old, but surprisingly, it still works!).
⚠ make sure to not only change the shortcut on your Start Menu, but to also unpin and then repin Edge to your taskbar again, to ensure Edge will always launch from the newer, modified shortcut. (replace the shortcut elsewhere where applicable in your case -- on your Desktop, other app launchers, etc.)
Sadly the script does not work for me.
It briefly pops up a blue Powershell window which closes itself and that's it. When i launch Edge it still has the rounded frame.
Ended up manually adding --enable-features=msForceNoRoundedCornerAndMargin to the taskbar shortcut in the AppData\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar folder :)
- Run PowerShell as Administrator (Hold Ctrl+Shift and click PowerShell icon)
Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass.\hide-edge-v149-rounded-corners.ps1
Run PowerShell as Administrator (Hold Ctrl+Shift and click PowerShell icon)
Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass
.\hide-edge-v149-rounded-corners.ps1
Kinda figured that was the case, just couldn't figure out how to run it as admin from the ps1 file.
I could not make the script bypass PowerShell execution policy by itself. There are other methods, but uglier, and compiling it into an .exe would be overkill and people should not just trust random .exe. I have updated the instructions instead.
I also updated the script to use numbered options, so user can easily choose workaround style, or reset shortcut to default.
It seems that msForceNoRoundedCornerAndMargin also removes the margin between Favorites Bar and web content.
It seems that
msForceNoRoundedCornerAndMarginalso removes the margin between Favorites Bar and web content.
That's a small price to pay really, i can deal with that.
It seems that
msForceNoRoundedCornerAndMarginalso removes the margin between Favorites Bar and web content.That's a small price to pay really, i can deal with that.
Use --disable-features=msFeatureGroupNewLookAndFeelHoldout, this feature don't remove Favorites Bar margin. Microsoft has become Microslop
It seems that
msForceNoRoundedCornerAndMarginalso removes the margin between Favorites Bar and web content.That's a small price to pay really, i can deal with that.
Use
--disable-features=msFeatureGroupNewLookAndFeelHoldout, this feature don't remove Favorites Bar margin. Microsoft has become Microslop
That one brings back the highlight bug in light theme, and it prevents webpages from opening images in the same tab.
is there any way to the the same on MacOS?
This is very helpful to me, thank you.
is there any way to the the same on MacOS?
open terminal and run:
open -a "Microsoft Edge" --args --disable-features=msFeatureGroupNewLookAndFeelHoldout
Now never totally close the opened edge app, you can close all its windows though, all new windows won't have the stupid rounded corners.
That's what Ive done.
Thank you so much!
Edge's rounded corners are such a fucking ugly UI. It was so disgusting.
Check out the new GUI tool, can optionally restore sidebar for anyone interested!
Is there a way to change the colour of the blue border ? or even disable i? thank you in advance Thorsten
Sorry, which blue border?

This script is mainly used to easily update possible Edge shortcuts without applying each of them manually.
Open Notepad or Notepad++, copy this whole script and paste into a new tab. Save the file and name it
hide-rounded-corner.ps1. Run the script as Administrator.Note: This is a PowerShell script, so the extension should be .ps1. If the script fails, run (as Administrator) using this sample:
powershell.exe -NoProfile -ExecutionPolicy Bypass -File "$env:USERPROFILE\Desktop\hide-rounded-corner.ps1"If rounded corner is still there. Open Edge, navigate to here:
edge://settings/system/manageSystem, disable Startup Boost, restart Edge.You can now remove the file, keep it, or help spread kindness to others.