Yes, with the start command. Example:

start http://www.google.com

That will use the user's default browser.
As stated by Joey, you should use a different format for URLs with special chars:

start "" "http://www.google.com"
Answer from Botz3000 on Stack Exchange
Discussions

open url using command line | Opera forums
this is a simple example of how to open a url through command line .. it is useful if you want to make a shortcut for a site in your desktop or you want to pin it in your taskbar "C:\Program Files (x86)\Opera\31.0.1889.99\opera.exe" --ran-launcher --remot... More on forums.opera.com
๐ŸŒ forums.opera.com
August 20, 2015
command line - Launching a website via the Windows commandline - Stack Overflow
I can see how there would be issues ... it a url.. which works. is there also issues just using start by itselft? start http://google.com?q=test on a mac currently cant test. 2018-03-13T15:47:26.397Z+00:00 ... Neither of those worked. rundll32 is the only thing that worked for me. But, I was executing this from Go not from a cmd ... More on stackoverflow.com
๐ŸŒ stackoverflow.com
KeePass / Discussion / Open Discussion: trigger CMD:// or URL:// from external command
Hi I have Keepass running with opened db and I would like to trigger the action in URL from external application (a windows bat-file) and pass some additional parameters to the URL/CMD (via environment variables?) More on sourceforge.net
๐ŸŒ sourceforge.net
April 8, 2022
python - How can I open url by clicking on hyperlink in CMD? - Stack Overflow
I wanna print some links to cmd and directly from cmd open these links by clicking on it. How can I do this? ... This depends on your terminal. And many other things as well. ... Sorry, I do not think it is possible by clicking on them but I can tell you you can use this to open some page in the browser: import webbrowser url ... More on stackoverflow.com
๐ŸŒ stackoverflow.com
๐ŸŒ
Vivaldi
forum.vivaldi.net โ€บ topic โ€บ 41180 โ€บ how-do-i-open-a-url-file-from-the-command-line
How do I open a URL file from the command line? | Vivaldi Forum
October 5, 2019 - It won't work directly from the Vivaldi exe like the dragon said above. URL files were and are very much a Microsoft thing, it was never really a standard, and so it's up to developers to care enough to support opening them.
๐ŸŒ
Server Fault
serverfault.com โ€บ questions โ€บ 1057801 โ€บ open-url-with-parameters-with-cmd
windows - Open url with parameters with cmd - Server Fault
March 21, 2021 - I changed default program for .docx and set to myopenwith.bat So when I clicked to any docx, it will open with myopenwith.bat myopenwith.bat has this code: start firefox https://www.dropbox.com/sea...
๐ŸŒ
Computer Hope
computerhope.com โ€บ tips โ€บ tip188.htm
Open Web Page from Windows Command Line
June 14, 2025 - Use the start command below to open a web page from the command line.
๐ŸŒ
Notepad++ Community
community.notepad-plus-plus.org โ€บ topic โ€บ 17439 โ€บ i-wanna-to-run-cmd-exe-to-open-url-in-default-browser
I wanna to run cmd.exe to open url in default browser | Notepad++ Community
April 13, 2019 - Instead, you have to tell console.run() to launch cmd.exe, and tell cmd.exe to launch start, and tell start to launch the URL. The following sequence of interactive commands opened three tabs of yahoo.com in my default browser:
๐ŸŒ
SLOCCount
dwheeler.com โ€บ essays โ€บ open-files-urls.html
How to easily open files and URLs from the command line
July 6, 2010 - This essay describes how to quickly open a file, directory, or URL from the command line in various platforms.
Find elsewhere
๐ŸŒ
YouTube
youtube.com โ€บ watch
How to start website using cmd windows - YouTube
Launching a website via windows commandlineStart website using cmd windowsStart website using cmd command lineopen url from command line windowscmd website c...
Published ย  November 9, 2023
๐ŸŒ
Opera
forums.opera.com โ€บ topic โ€บ 11382 โ€บ open-url-using-command-line
open url using command line | Opera forums
August 20, 2015 - this is a simple example of how to open a url through command line .. it is useful if you want to make a shortcut for a site in your desktop or you want to pin it in your taskbar "C:\Program Files (x86)\Opera\31.0.1889.99\opera.exe" --ran-launcher --remot...
๐ŸŒ
Chron.com
smallbusiness.chron.com โ€บ open-internet-through-cmd-64114.html
How to Open the Internet Through CMD
February 5, 2019 - Press "Win-R," type "cmd" and press "Enter" to open the Command Prompt. Type "start iexplore" and press "Enter" to open Internet Explorer and view its default home screen. Alternatively, type "start firefox," "start opera" or "start chrome" and press "Enter" to open one of those browsers. Add an address to the command to open that particular address in a browser...
๐ŸŒ
Mozilla Bugzilla
bugzilla.mozilla.org โ€บ show_bug.cgi
111539 - Command line option to open url in existing window (support -remote for Win)
January 27, 2022 - I would like to open a url in a current browser window from a command line. This way I could click desktop links or links in my non-Mozilla mail client and have them reuse the open browser window. If no window is open the command would open a new one. ->cmd line feature ยท
๐ŸŒ
SourceForge
sourceforge.net โ€บ home โ€บ browse โ€บ keepass โ€บ discussion
KeePass / Discussion / Open Discussion: trigger CMD:// or URL:// from external command
April 8, 2022 - Opening the URL of an entry is possible using the -entry-url-open command line parameter. https://keepass.info/help/base/cmdline.html ยท You could retrieve parameters using {CMD:...} (e.g. reading them from a file), {CLIPBOARD}, ...
๐ŸŒ
Stack Overflow
stackoverflow.com โ€บ questions โ€บ 49591913 โ€บ how-can-i-open-url-by-clicking-on-hyperlink-in-cmd
python - How can I open url by clicking on hyperlink in CMD? - Stack Overflow
I wanna print some links to cmd and directly from cmd open these links by clicking on it. How can I do this? ... This depends on your terminal. And many other things as well. ... Sorry, I do not think it is possible by clicking on them but I can tell you you can use this to open some page in the browser: import webbrowser url = โ€œhttp://google.com/โ€œ webbrowser.open(url)
๐ŸŒ
IQCode
iqcode.com โ€บ code โ€บ other โ€บ open-link-with-cmd
open link with cmd Code Example
February 3, 2022 - open url cmd line opening link using cmd open weblink with cmd how to open link through cmd How to open an link using cmd open link windows cmd open link using cmd how open browser link from cmd command how to open a link using cmd\ open link in browser cmd open a link in cmd open links in ...
Top answer
1 of 4
5

You know how sometimes the answer to the question you ask is not necessarily the answer you need? I have a vague suspicion this might be one of those times.

If this is a Windows machine you're trying to reboot, you can reboot it remotely without needing to use a CGI script served by the remote host. If the account you're logged in with on the triggering PC also has privileges on the remote PC, you can trigger the reboot with the shutdown command.

shutdown /m \\remotePC /r /t 0

Do shutdown /? in a cmd console for more info. Or if you must authenticate, you can use wmic instead.

wmic /node:remotePC /user:remotePCadmin /password:remotePCpass process call create "shutdown -r -t 0"

In case I was mistaken, here's the answer to the question you asked. The fastest way to execute a remote CGI script would be to use an XMLHTTPRequest with Windows Script Host (VBScript or JScript). Here's an example.

@if (@CodeSection == @Batch) @then
@echo off & setlocal

set "URL=http://192.168.1.100/cgi-bin/reboot"
cscript /nologo /e:jscript "%~f0" "%URL%"

goto :EOF
@end // end batch / begin JScript chimera

var x = WSH.CreateObject("Microsoft.XMLHTTP");

x.open("GET",WSH.Arguments(0),true);
x.setRequestHeader('User-Agent','XMLHTTP/1.0');
x.send('');
while (x.readyState != 4) WSH.Sleep(50);

For what it's worth, you can also parse x.responseText as needed. You can scrape it as flat text, or even evaluate it as a hierarchical DOM object. This answer demonstrates such parsing. And if you just can't get enough, here are more examples.


If you'd rather have something simpler at the expense of efficiency, you can invoke a PowerShell command.

@echo off & setlocal

set "URL=http://192.168.1.100/cgi-bin/reboot"
powershell "ipmo BitsTransfer; Start-BitsTransfer \"%URL%\" \"%temp%\a\""
del /q "%temp%\a"

goto :EOF

You could probably alternatively use Invoke-WebRequest to avoid the temporary file, but Invoke-WebRequest requires PowerShell version 3 or newer. Start-BitsTransfer works with PowerShell version 2, so it should work on more computers. One might also use the [System.Net]::WebRequest .NET class, but it gets a little complicated constructing all the objects needed to proceed beyond fetching the HTTP headers to having the web server serve the web page. If you're curious, it looks something like this:

powershell "void.GetResponse().GetResponseStream())).ReadToEnd()"

Not exactly what I'd call simple. In hybrid format for easier readability:

<# : batch portion
@echo off & setlocal

set "URL=http://192.168.1.100/cgi-bin/reboot"
powershell -noprofile "iex (${%~f0} | out-string)"

goto :EOF

: end batch / begin PowerShell hybrid chimera #>

$request = [Net.WebRequest]::Create($env:URL)
$response = $request.GetResponse()
$stream = $response.GetResponseStream()
$reader = new-object IO.StreamReader($stream)
[void]$reader.ReadToEnd()

In any case, any PowerShell solution will be a second or two slower than the JScript solution near the top of this answer. powershell.exe takes a second or two to load (indeed, several seconds if it's not been loaded since Windows was last rebooted); whereas cscript.exe fires nearly instantly.

2 of 4
4

If you cannot download anything, then Windows PowerShell is the best option. You can call it from a PS script file, or directly from the command line in a batch file:

powershell.exe -noprofile -command "Invoke-WebRequest -Uri http://192.168.1.100/cgi-bin/reboot"

You can also consider Curl for that type of process. There is no equivalent in Windows, so it will require a download.

curl http://192.168.1.100/cgi-bin/reboot

Curl will not open a browser window, and has great command line options (See curl -help), and will return error codes for batch file error handling.

๐ŸŒ
Raspberry Pi Forums
forums.raspberrypi.com โ€บ board index โ€บ software โ€บ raspberry pi os
Opening URL in Chromium from command line - Raspberry Pi Forums
Sun Feb 06, 2022 8:03 pm Not from CLi but true from a xterm (right click - open url), if you are in CLI there is no GUI for Chromium to run in. Thanks for putting that right.
๐ŸŒ
Baeldung
baeldung.com โ€บ home โ€บ web โ€บ how to open a directory and a url through the linux cli
How to Open a Directory and a URL Through the Linux CLI | Baeldung on Linux
February 1, 2024 - The xdg-open command is used to open files, directories, and URLs using the default applications associated with them. For instance, letโ€™s run the xdg-open command to open the /home/author/Documents/folder directory through the command line: ...