How-To Geek

How to preview safari links before opening on iphone, ipad, and mac.

Wondering whether some hyperlinked text in an email or a website is legit?

Quick Links

How to preview safari links before opening on mac, how to preview safari links before opening on iphone and ipad.

Peeking at the URL of a link that you're about to open is a good way to make sure the URL is what you expect and not a trick. Here's how to preview links in Safari for Mac, iPhone, and iPad.

Popular desktop web browsers have featured URL status bars for decades. But Safari for Mac doesn't enable one by default. If you want to quickly check the URL of a link, you can do it by enabling the status bar.

Related: What Is A URL (Uniform Resource Locator)?

First, open the Safari app on your Mac. Click the "View" section in the menu bar and choose the "Show Status Bar" option.

With this enabled, when you hover over any link, you will see its full URL address in the status bar in the bottom-left corner of the page.

If you ever want to disable this link preview, click View > Hide Status Bar in the menu bar at the top of the screen.

Unlike the Mac, Safari on iPhone and iPad doesn't have a status bar. But it does let you peek into the page that you want to open. You can tap and hold any link to load the page in a pop-up preview window. If you don't like the full preview, you can switch to only viewing the URL (like Safari on Mac).

To get started, open a page in Safari on your iPhone or iPad. Tap and hold any link on the page.

If you're running iOS 13 , iPadOS 13, or higher, you will see a thumbnail preview of the page pop-up. To preview the URL instead, tap the "Hide Preview" button located at the top of the pop-up window.

The thumbnail will disappear and you'll see the URL listed in the box. If it looks safe and you want to open the page from this pop-up, tap the "Open" button in the menu list below the preview pop-up.

If you want to get the thumbnail peek back later, just tap and hold a link again and select "Tap to show preview" at the top of the pop-up window.

Keeping an eye on URLs is just one more way that browsing with more knowledge will help you avoid web-based scams and keep you safer on the web.

Related: Why Do Websites Redirect to Fake “Congratulations” Gift Card Pages?

  • Apple Watch
  • Accessories
  • Digital Magazine – Subscribe
  • Digital Magazine – Info
  • Smart Answers
  • 11th-gen iPad
  • New AirPods
  • Best Mac antivirus
  • Best Mac VPN

When you purchase through links in our articles, we may earn a small commission. This doesn't affect our editorial independence .

How to use Safari on a Mac

Karen Haslam

Safari is the web browser app bundled with all Macs as part of macOS. You don’t have to use it – if you prefer to use Chrome or Firefox, for example, you can install those apps for your web surfing needs. But in our experience, Safari is a good option – and as you can see from our round-up of best web browser apps for the Mac , it’s pretty much the best you can get.

If you are new to Safari this article will help you find your way around the app. And if you are a seasoned Safari user we will reveal a few Safari tips and tricks that you might not know, including some of the fab new features in Safari 11, the latest version of Safari for Mac.

If you’d like to read about using Safari on the iPad or iPhone, read this .

How to get the latest version of Safari for Mac

First things first. You will want to make sure you have the latest version of Safari. At the time of writing the most up-to-date version is Safari 11.1.

Here’s how to find out which version of Safari you are running:

  • Open Safari.
  • Click on Safari > About Safari in the menu.
  • The resulting window will reveal the version number.

As long as your copy of MacOS – the Mac operating system – is up to date your copy of Safari should be because Safari is bundled as part of an operating system update.

However, you don’t have to be using the latest version of macOS to have the latest version of Safari. Apple is bundling Safari 11 with High Sierra, Sierra and El Capitan versions of the Mac OS. If you need to update your version of MacOS read this: how to update your Mac operating system software .

Now that you have the latest version of Safari you can start enjoying some of the new features that we will discuss below.

Safari basics

If you are a surfing novice you might want to familiarise yourself with these tips.

We’ll start off with the basics, such as how to get into Safari, how to search, and other useful pointers. You can skip this bit if you aren’t a Safari beginner, there are plenty of tips below that you might find useful.

You can find Safari in the Dock at the bottom of your Mac’s screen. Its icon looks like a compass.

safari open url

How to use Safari

The big bar at the top of the Safari window is where you can enter a website URL or a search term to either take you directly to a website, or to a list of pages that match your query.

It will automatically search in Google (but you can change it so it defaults to another search engine).

You rarely have to enter a complete URL for a website. Once you have visited a site once you only need to type a few letters of its name and it will autofill the rest of the URL.

For example, type: ‘Face’ and it will autofill the rest of the URL and when you press enter it will take you straight to Facebook.

How to make it easy to find your favourite sites in Safari

There are lots of ways of making it easy to get to websites you frequently visit.

When you open a new tab (see below for details of how to do that) you will see your Favourites view including Frequently Visited Sites. You could also choose to see a Top Sites view, set a Homepage, just see an empty page, or have the Same Page show up. These are all options you can access in Safari > Preferences > General. Just click on the menu beside New tabs open with.

safari open url

If you choose the Top Sites view you can adjust it to show 6, 12 or 24 sites. To add and remove Top Sites hover over the preview until you see an x and a pin icon. Pin those sites you wish to keep and click x on those you don’t image you will want to find again. The sites that appear in Top Sites tend to be those you visit most frequently.

You can choose one of these views for every time you open a new Safari window.

How to Pin a site in Safari

In Safari you can also ‘Pin’ favourite sites to the menu bar – a simple way of adding a shortcut to Facebook, YouTube or any site you visit frequently.

When you Pin a site you will see a small icon representing that site on the left of your tabs.

To Pin a particular web page right- or control-click on the tab and choose Pin Tab. Then it’s very easy to go straight to that site.

safari open url

Using tabs in Safari

Back to tabs. You can open multiple tabs in a Safari window, this means that rather than having a different Safari window open for every website you are on, you can just have one Safari window open and multiple pages accessible through that.

To open a new tab press Command + T.

There are two ways that you can see a preview of the different tabs you have open:

  • You can see a short summary of the name of the web page on the tabs themselves. This might be sufficient if you only have one or two tabs open, but once you have more than eight you’ll probably find the summary is too short to be useful.
  • Or, you can click on the icon that looks like two boxes on the right of the search/URL box. This will show a thumbnail view of all the web pages you have open.

While we’re on the subject of Tabs, you can close a single tab just by hovering over the tab and clicking on the x that shows up in the corner of that tab.

It’s also possible to close all but one tab. Just hold down the Option/Alt key when you click on the x to get rid of all the other tabs that are open, except for the page on that tab.

How to tell which Safari tabs are playing audio

Not everyone wants to surf the web in silence though. There is lots of very worthy audio and video content available on the web and no doubt many surfers wouldn’t want to miss out on that.

The problem is when you have multiple web pages open and more than one of them is blaring out audio.

Luckily there is another Safari tip to fix that.

You can identify which of your open tabs is playing audio by the speaker symbol that appears in the far right of the Safari tab associated with that web page.

It’s possible to mute the audio with a single click on the speaker symbol without even opening the tab.

safari open url

And if more than one Safari webpage is playing audio you can choose to mute them all at once. Just click on the speaker symbol in the URL bar and choose Mute all Tabs.

Alternatively, you can Option/Alt-click on the speaker icon of the tab you do wish to listen to and mute the audio on all the other tabs.

safari open url

How to reopen all windows from the last session

Here’s another useful tip. You can easily reopen all the tabs you had open last time you were using Safari.

Click History > Reopen All Windows from Last Session to quickly recover all the windows you were recently looking at. You might also find this helpful: How to export bookmarks from Chrome to Safari

How to show the full URL in Safari

Another handy Safari tip. In Yosemite Safari stopped showing the whole URL – a feature designed to help avoid users being taken in by phishing scams, wherein the URL is obfuscated. In other words, if you’re visiting https://macworld.co.uk/this/page/that/page then all you’ll see in the address bar is macworld.co.uk.

If this isn’t what you want, perhaps you want to see the full URL of the article you are reading, you can change things so that the whole URL is shown.

Open Safari’s preferences dialog box (Cmd+,) then click the Advanced icon and put a check alongside Show Full Website Address.

How to change how you view websites in Safari

One of our favourite features in Safari 11 is the extra control we have over the web. You can tweak the settings of specific websites so that they suit you for example.

How to change the font size on a website

You can tweak your settings so that when you visit a specific site the images and text are bigger – perfect if you are frustrated to find that the text on a favourite website is a bit too small for your eyes.

Here’s how to enlarge (or reduce) the font size on a particular website so that it stays that size whether you visit:

  • Go to Safari > Preferences.
  • Click on the Websites tab.
  • Click on Page Zoom.
  • Find the site you want to customise (any site you have open or have recently visited will be listed here).
  • Choose a number bigger or smaller than 100% depending on how large you want the text and images to be.

You can do this on a per website basis, or if you frequently find that the text on websites is too small for you, you can choose to default to the percentage that suits you wherever you go on the web. Note that not all websites are created the same so some will naturally have larger type than others.

safari open url

To choose the zoom percentage for all websites, click in the drop down box beside “When visiting other websites”.

Another benefit of having access to these controls that allow you to change the way you view the web is that it enables you to stop seeing ads and auto-playing videos. We’ll look at that below.

How to stop ads and auto-playing videos in Safari

Another enticing feature of Safari is the way you can choose to adjust the settings so that you never see another ad or auto-playing video again. We’ll look at how to do that next.

How to stop autoplay audio and video in Safari

Perhaps you are frustrated by auto-playing video blaring out every time you visit a website.

With Safari 11 you can disable autoplay video, so you will never again have to hear voices while you are browsing the web. Here’s what to do:

  • Open the offending website.
  • Click on Safari > Settings for This Website (or right-click the URL box and select Settings for This Website).
  • Allow All Auto-Play
  • Stop Media with Sound
  • Never Auto-Play

Stop Media with Sounds is the default option, and it will essentially stop any video from starting if the sound is set to be on. If the video is set to play silently it will still run but you won’t hear it, unless you choose to.

If you would rather not let auto-playing video play, you can choose Never Auto-Play.

Remember that if you adjust the settings this way it will only apply to autoplay videos on that website. If you’d like to never see an autoplaying video again follow these steps:

  • Go to Safari > Preferences and click on Websites.

And there is an option below to choose the same settings “When visiting other websites”.

We have a complete tutorial that explains how to use this feature here: How to stop autoplay video in Safari & Chrome on Mac .

We also cover how to stop Safari asking to use your location data here .

How to stop seeing ads on websites in Safari

While ads pay a part of our wage, we realise that some ads can really reduce the enjoyment of web browsing. Usually these are ads that have something wrong with the way they have been coded and aren’t behaving as intended, or even worse they are spam ads that have crept onto the ad networks. We are honestly as frustrated as you are!

One of the big changes Apple bought to Safari 11 was the ability to really manage the ads that you see – this was part of Apple’s effort to make the web work better. Effectively, if Apple can remove ads that aren’t behaving as intended and are jamming up page loading times and the like, then Safari will perform quicker, which means that the surfer has a better time surfing.

There are a few ways you can take advantage of these anti-ad related features in Safari 11.

One way is to choose to surf the web – or certain pages – in Reader mode.

safari open url

Reader mode is a way of viewing webpages that Apple introduced back in 2010 in Safari 5. Reader displays just the text and images from a webpage, without any of the other page furniture. We think it is a bit like reading a Word document or a PDF. The feature hasn’t changed much over the years, but in Safari 11 it’s became possible to choose for a site to always be viewed in Reader Mode.

First, here’s how to view a site in Reader mode:

  • Click on the stack of lines to the left of the URL bar.
  • This will automatically change the webpage to Reader view.
  • Click on the stack of lines to turn Reader view off.

It’s worth checking how a site appears in this mode before switching over to it because not all sites implement it particularly well (sometimes you will find that an article stops abruptly because only one page has been carried into Reader view). Some sites don’t have a Reader view at all (such as Apple, for example).

And here is how to customise your settings so that whenever you visit that site the pages are viewed in Reader mode:

  • Click on Reader.
  • Find the site you want to customise (any site you have open, or have recently visited will be listed here).
  • Toggle the drop-down menu beside that site to On.

A quicker way to do this is to right-click or control-click on the stack of lines beside the URL and choose Use Reader Automatically.

Or, as long as you are on the website you wish to change the setting for, you can click on Safari > Settings for this Website, and choose Use Reader When Available.

How to surf in private using Safari

Another useful feature in Safari is the option to use a private browsing window. This doesn’t just keep your browsing habits private from someone else who has access to your Mac, it also means that you are incognito – in other words even the websites you are visiting don’t have any information about you.

Go to Safari > File > New Private Window (or shift-cmd-n). You can tell if a window is private because the search bar will be grey. Any new tabs you open in this window will be private.

Alternatively, to open a Private Browsing window you can click shift, command and N.

You can tell it’s a private window because the URL field will be greyed out.

Hold down Option/Alt while picking Private Browsing to quickly switch it on and bypass the ‘Do you want to switch on Private Browsing?’ alert window if you happen to see it frequently. We have a complete guide to private browsing on Safari here .

For even more privacy, you can choose to always search with privacy-obsessed DuckDuckGo as your default search engine. Go to Safari > Preferences > Search, and click on the Search Engine. Then select Duck Duck Go from the Search Engine dropdown list. You can choose from Google, Bing, Yahoo or DuckDuckGo.

How to delete your histroy in Safari

If you didn’t search using a private browsing window you can still delete your history and evidence of what you were up to.

  • Click on History.
  • Scroll down and click on Clear History.
  • You can choose to clear history for Today, the last hour, today and yesterday, or all history.
  • You’ll see a warning that Clearing history will remove related cookies and other website data. Basically this is warning you that if you go ahead and Clear History you may find that you have to log onto websites, or shopping cart information may disappear.
  • If you are happy with that then click on Clear history.

We have a complete tutorial all about how to delete your browser history on a Mac here .

How to delete cookies in Safari

Another new feature that came in Safari 11 was the introduction of privacy protection, a feature that’ll stop those annoying Amazon adverts showing you products after you’ve bought them.

Safari actively tries to block the cross-site tracking data that powers targeted adverts. While it won’t completely stop it, it should have a noticeable effect when using the browser.

According to Apple this isn’t an attempt to block ads, but rather to protect your privacy.

This means that you should no longer need to delete cookies if you want to stop seeing targeted ads (cookies have also been known to affect the price for goods if you have previously shown an interest in a product so deleting cookies could avoid such practices).

If you want to go a step further regarding cookies in Safari 11 there are some preferences changes you can make.

  • Beside Website tracking click on Ask websites not to track me.
  • Beside Cookies and website data click on Block all cookies.

If you aren’t using Safari 11 you can still delete cookies.

  • Click on the Privacy tab.
  • Click on Remove All Website Data…

Here’s how to add your own background image to Safari.

Author: Karen Haslam , Managing Editor

safari open url

Karen has worked on both sides of the Apple divide, clocking up a number of years at Apple's PR agency prior to joining Macworld more than two decades ago. Karen's career highlights include interviewing Apple's Steve Wozniak and discussing Steve Jobs’ legacy on the BBC. Having edited the U.K. print and online editions of Macworld for many years, more recently her focus has been on SEO and evergreen content as well product recommendations and buying advice on Macworld.com.

Recent stories by Karen Haslam:

  • macOS 15 Sequoia superguide: Eveything you need to know about the Mac update
  • How to download macOS beta
  • Apple Events 2024: Apple’s event plans

Blazing fast. Incredibly private.

safari open url

Safari is the best way to experience the internet on all your Apple devices. It brings robust customization options, powerful privacy protections, and optimizes battery life — so you can browse how you like, when you like. And when it comes to speed, it’s the world’s fastest browser. 1

Performance

More with the battery. less with the loading..

With a blazing-fast JavaScript engine, Safari is the world’s fastest browser. 1 It’s developed to run specifically on Apple devices, so it’s geared to make the most out of your battery life and deliver long-lasting power.

safari open url

Increased performance

We’re always working to make the fastest desktop browser on the planet even faster.

safari open url

Improved power efficiency

Safari lets you do more online on a single charge.

safari open url

Up to 4 hours more streaming videos compared with Chrome 3

safari open url

Up to 17 hours of video streaming 3

Best-in-class browsing

Safari outperforms both Mac and PC browsers in benchmark after benchmark on the same Mac. 4

  • JetStream /
  • MotionMark /
  • Speedometer /

JavaScript performance on advanced web applications. 4

Safari vs. other Mac browsers

Safari on macOS

Chrome on macOS

Edge on macOS

Firefox on macOS

Safari vs. Windows 11 browsers

Chrome on Windows 11

Edge on Windows 11

Firefox on Windows 11

Rendering performance of animated content. 4

Web application responsiveness. 4

4K video streaming

See your favorite shows and films in their best light. Safari supports in-browser 4K HDR video playback for YouTube, Netflix, and Apple TV+. 5 And it runs efficiently for longer-lasting battery life.

safari open url

Privacy is built in.

Online privacy isn’t just something you should hope for — it’s something you should expect. That’s why Safari comes with industry-leading privacy protection technology built in, including Intelligent Tracking Prevention that identifies trackers and helps prevent them from profiling or following you across the web. Upgrading to iCloud+ gives you even more privacy protections, including the ability to sign up for websites and services without having to share your personal email address.

safari open url

Intelligent Tracking Prevention

safari open url

Safari stops trackers in their tracks.

What you browse is no one’s business but your own. Safari has built‑in protections to help stop websites and data-collection companies from watching and profiling you based on your browsing activity. Intelligent Tracking Prevention uses on‑device intelligence to help prevent cross‑site tracking and stops known trackers from using your IP address — making it incredibly difficult to learn who you are and what you’re interested in.

Privacy Report

Safari makes it simple to see how your privacy is protected on all the websites you visit. Click Privacy Report in the Safari menu for a snapshot of cross-site trackers currently prevented from profiling you on the website you’re visiting. Or view a weekly Privacy Report to see how Safari protects you as you browse over time.

safari open url

Customization

Putting the you in url..

Safari is more customizable than ever. Organize your tabs into Tab Groups so it’s easy to go from one interest to the next. Set a custom background image and fine-tune your browser window with your favorite features — like Reading List, Favorites, iCloud Tabs, and Siri Suggestions. And third-party extensions for iPhone, iPad, and Mac let you do even more with Safari, so you can browse the way you want across all your devices.

safari open url

Safari Profiles allow you to separate your history, extensions, Tab Groups, favorites, cookies, and more. Quickly switch between profiles for topics you create, like Personal and Work.

safari open url

Web apps let you save your favorite websites to the Dock on Mac and to the Home Screen on iPhone and iPad. A simplified toolbar and separate settings give you an app-like experience.

safari open url

Safari Extensions add functionality to your browser to help you explore the web the way you want. Find and add your favorite extensions in the dedicated Safari category on the App Store.

safari open url

Save and organize your tabs in the way that works best for you. Name your Tab Groups, edit them, and switch among them across devices. You can also share Tab Groups — making planning your next family trip or group project easier and more collaborative.

safari open url

Smart Tools

Designed to help your work flow..

Built-in tools create a browsing experience that’s far more immersive, intuitive, and immediate. Get detailed information about a subject in a photo with just a click, select text within any image, instantly translate an entire web page, and quickly take notes wherever you are on a site — without having to switch apps.

safari open url

Notes is your go-to app to capture any thought. And with the Quick Note feature, you can instantly jot down ideas as you browse websites without having to leave Safari.

safari open url

Translation

Translate entire web pages with a single click. You can also get translations for text in images and paused video without leaving Safari.

Interact with text in any image or paused video on the web using functions like copy and paste, translate, and lookup. 6

safari open url

Visual Look Up

Quickly learn more about landmarks, works of art, breeds of dogs, and more with only a photo or an image you find online. And easily lift the subject of an image from Safari, remove its background, and paste it into Messages, Notes, or other apps.

safari open url

Surf safe and sound.

Strong security protections in Safari help keep you safe. Passkeys introduce a safer way to sign in. iCloud Keychain securely stores and autofills passkeys and passwords across all your devices. Safari also notifies you when it encounters suspicious websites and prevents them from loading. Because it loads each web page in a separate process, any harmful code is always confined to a single browser tab so it won’t crash the entire application or access your data. And Safari automatically upgrades sites from HTTP to the more secure HTTPS when available.

safari open url

Passkeys introduce a more secure and easier way to sign in. No passwords required.

Passkeys are end-to-end encrypted and safe from phishing and data leaks, and they are stronger than all common two-factor authentication types. Thanks to iCloud Keychain, they work across all your Apple devices, and they even work on non-Apple devices.

Learn more about passkeys

safari open url

Apple Pay and Wallet make checkout as easy as lifting a finger.

Apple Pay is the easiest and most secure way to shop on Safari — allowing you to complete transactions with Face ID or Touch ID on your iPhone or iPad, with Touch ID on your MacBook Pro or MacBook Air, or by double-clicking the side button on your Apple Watch.

Learn more about Apple Pay

With AutoFill, you can easily fill in your previously saved credit card information from the Wallet app during checkout. Your credit card details are never shared, and your transactions are protected with industry-leading security.

Same Safari. Different device.

Safari works seamlessly and syncs your passwords, bookmarks, history, tabs, and more across Mac, iPad, iPhone, and Apple Watch. And when your Mac, iOS, or iPadOS devices are near each other, they can automatically pass what you’re doing in Safari from one device to another using Handoff. You can even copy images, video, or text from Safari on your iPhone or iPad, then paste into another app on your nearby Mac — or vice versa.

safari open url

When you use Safari on multiple devices, your tabs carry over from one Apple device to another. So you can search, shop, work, or browse on your iPhone, then switch to your iPad or Mac and pick up right where you left off.

Save web pages you want to read later by adding them to your Reading List. Then view them on any of your iCloud-connected devices — even if you’re not connected to the internet.

iCloud Keychain securely stores your user names, passkeys, passwords, and credit card numbers and keeps them up to date on your trusted devices. So you can easily sign in to your favorite websites — as well as apps on iOS and iPadOS — and quickly make online purchases.

safari open url

Designed for developers.

Deep WebKit integration between Mac hardware and macOS allows Safari to deliver the fastest performance and the longest battery life of any browser on the platform, while supporting modern web standards for rich experiences in the browser. WebKit in macOS Sonoma includes optimizations that enable even richer browsing experiences, and give developers more control over styling and layout — allowing for more engaging content.

Make Safari your default browser

Customize your start page, view your browsing privacy report, monitor your saved passwords, use apple pay in safari, view your tabs across all your devices, read the safari user guide, get safari support.

  • Skip to main content
  • Skip to search
  • Skip to select language
  • Sign up for free

Window: open() method

The open() method of the Window interface loads a specified resource into a new or existing browsing context (that is, a tab, a window, or an iframe ) under a specified name.

A string indicating the URL or path of the resource to be loaded. If an empty string ( "" ) is specified or this parameter is omitted, a blank page is opened into the targeted browsing context.

A string, without whitespace, specifying the name of the browsing context the resource is being loaded into. If the name doesn't identify an existing context, a new context is created and given the specified name. The special target keywords , _self , _blank , _parent , _top , and _unfencedTop can also be used. _unfencedTop is only relevant to fenced frames .

This name can be used as the target attribute of <a> or <form> elements.

A string containing a comma-separated list of window features in the form name=value — or for boolean features, just name . These features include options such as the window's default size and position, whether or not to open a minimal popup window, and so forth. The following options are supported:

Indicates that you want the browser to send an Attribution-Reporting-Eligible header along with the open() call. This call must be made with transient activation (i.e. inside a user interaction event handle such as click ), within five seconds of user interaction. On the server-side this is used to trigger sending an Attribution-Reporting-Register-Source header in the response to complete registration of an attribution source.

In addition, the browser is also triggered to store the associated source data (as provided in the Attribution-Reporting-Register-Source response header) when the open() method completes.

See the Attribution Reporting API for more details.

Note: open() calls cannot be used to register an attribution trigger.

If this feature is enabled, it requests that a minimal popup window be used. The UI features included in the popup window will be automatically decided by the browser, generally including an address bar only.

If popup is not enabled, and there are no window features declared, the new browsing context will be a tab.

Note: Specifying any features in the windowFeatures parameter, other than noopener or noreferrer , also has the effect of requesting a popup.

To enable the feature, specify popup either with no value at all, or else set it to yes , 1 , or true .

Example: popup=yes , popup=1 , popup=true , and popup all have identical results.

Specifies the width of the content area, including scrollbars. The minimum required value is 100.

Specifies the height of the content area, including scrollbars. The minimum required value is 100.

Specifies the distance in pixels from the left side of the work area as defined by the user's operating system where the new window will be generated.

Specifies the distance in pixels from the top side of the work area as defined by the user's operating system where the new window will be generated.

If this feature is set, the new window will not have access to the originating window via Window.opener and returns null .

When noopener is used, non-empty target names, other than _top , _self , and _parent , are treated like _blank in terms of deciding whether to open a new browsing context.

If this feature is set, the browser will omit the Referer header, as well as set noopener to true. See rel="noreferrer" for more information.

Note: Requested position ( top , left ), and requested dimension ( width , height ) values in windowFeatures will be corrected if any of such requested value does not allow the entire browser popup to be rendered within the work area for applications of the user's operating system. In other words, no part of the new popup can be initially positioned offscreen.

Return value

If the browser successfully opens the new browsing context, a WindowProxy object is returned. The returned reference can be used to access properties and methods of the new context as long as it complies with the same-origin policy security requirements.

null is returned if the browser fails to open the new browsing context, for example because it was blocked by a browser popup blocker.

Description

The Window interface's open() method takes a URL as a parameter, and loads the resource it identifies into a new or existing tab or window. The target parameter determines which window or tab to load the resource into, and the windowFeatures parameter can be used to control to open a new popup with minimal UI features and control its size and position.

Remote URLs won't load immediately. When window.open() returns, the window always contains about:blank . The actual fetching of the URL is deferred and starts after the current script block finishes executing. The window creation and the loading of the referenced resource are done asynchronously.

Modern browsers have strict popup blocker policies. Popup windows must be opened in direct response to user input, and a separate user gesture event is required for each Window.open() call. This prevents sites from spamming users with lots of windows. However, this poses an issue for multi-window applications. To work around this limitation, you can design your applications to:

  • Open no more than one new window at once.
  • Reuse existing windows to display different pages.
  • Advise users on how to update their browser settings to allow multiple windows.

Opening a new tab

Opening a popup.

Alternatively, the following example demonstrates how to open a popup, using the popup feature.

It is possible to control the size and position of the new popup:

Progressive enhancement

In some cases, JavaScript is disabled or unavailable and window.open() will not work. Instead of solely relying on the presence of this feature, we can provide an alternative solution so that the site or application still functions.

Provide alternative ways when JavaScript is disabled

If JavaScript support is disabled or non-existent, then the user agent will create a secondary window accordingly or will render the referenced resource according to its handling of the target attribute. The goal and the idea are to provide (and not impose ) to the user a way to open the referenced resource.

The above code solves a few usability problems related to links opening popups. The purpose of the event.preventDefault() in the code is to cancel the default action of the link: if the event listener for click is executed, then there is no need to execute the default action of the link. But if JavaScript support is disabled or non-existent on the user's browser, then the event listener for click is ignored, and the browser loads the referenced resource in the target frame or window that has the name "WikipediaWindowName" . If no frame nor window has the name "WikipediaWindowName" , then the browser will create a new window and name it "WikipediaWindowName" .

Note: For more details about the target attribute, see <a> or <form> .

Reuse existing windows and avoid target="_blank"

Using "_blank" as the target attribute value will create several new and unnamed windows on the user's desktop that cannot be recycled or reused. Try to provide a meaningful name to your target attribute and reuse such target attribute on your page so that a click on another link may load the referenced resource in an already created and rendered window (therefore speeding up the process for the user) and therefore justifying the reason (and user system resources, time spent) for creating a secondary window in the first place. Using a single target attribute value and reusing it in links is much more user resources friendly as it only creates one single secondary window, which is recycled.

Here is an example where a secondary window can be opened and reused for other links:

  • Same-origin policy

If the newly opened browsing context does not share the same origin , the opening script will not be able to interact (reading or writing) with the browsing context's content.

For more information, refer to the Same-origin policy article.

Accessibility concerns

Avoid resorting to window.open().

It is preferable to avoid resorting to window.open() , for several reasons:

  • Modern browsers offer a popup-blocking feature.
  • Modern browsers offer tab-browsing, and tab-capable browser users prefer opening new tabs to opening new windows in most situations.
  • Users may use browser built-in features or extensions to choose whether to open a link in a new window, in the same window, in a new tab, the same tab, or in the background. Forcing the opening to happen in a specific way, using window.open() , will confuse them and disregard their habits.
  • Popups don't have a menu toolbar, whereas new tabs use the user interface of the browser window; therefore, many users prefer tab-browsing because the interface remains stable.

Never use window.open() inline in HTML

Avoid <a href="#" onclick="window.open(…);"> or <a href="javascript:window\.open(…)" …> .

These bogus href values cause unexpected behavior when copying/dragging links, opening links in a new tab/window, bookmarking, or when JavaScript is loading, errors, or is disabled. They also convey incorrect semantics to assistive technologies, like screen readers.

If necessary, use a <button> element instead. In general, you should only use a link for navigation to a real URL .

Always identify links leading to a secondary window

Identify links that will open new windows in a way that helps navigation for users.

The purpose is to warn users of context changes to minimize confusion on the user's part: changing the current window or popping up new windows can be very disorienting to users (in the case of a popup, no toolbar provides a "Previous" button to get back to the previous window).

When extreme changes in context are explicitly identified before they occur, then the users can determine if they wish to proceed or so they can be prepared for the change: not only they will not be confused or feel disoriented, but more experienced users can better decide how to open such links (in a new window or not, in the same window, in a new tab or not, in "background" or not).

  • WebAIM: Links and Hypertext - Hypertext Links
  • MDN / Understanding WCAG, Guideline 3.2
  • G200: Opening new windows and tabs from a link only when necessary
  • G201: Giving users advanced warning when opening a new window

Specifications

Browser compatibility.

BCD tables only load in the browser with JavaScript enabled. Enable JavaScript to view data.

  • <form>
  • window.close()
  • window.closed
  • window.focus()
  • window.opener
  • rel="opener" and rel="noopener"

View in English

Tools, documentation, forums, videos, and more.

Safari Technology Preview

Get a sneak peek at upcoming web technologies in macOS and iOS with Safari Technology Preview and experiment with these technologies in your websites and extensions.

  • Safari Technology Preview for macOS Sonoma Requires macOS 14 or later
  • Safari Technology Preview for macOS Ventura Requires macOS 13 or later
  • Release Notes

June 5, 2024

Safari beta

Try out the next version of Safari for upcoming macOS releases. To access the latest beta versions of Safari, sign in with your Apple ID.

View downloads

Release Date

September 20, 2021

Guides and sample code

Get details on implementing web technologies with guides, reference, and sample code.

  • Safari Web Extensions
  • Apple Pay on the Web
  • Security Keys
  • Video Content in Safari
  • More Safari Documentation

Watch and learn from our engineers as they show how to bring the latest web technologies to your websites on Safari.

  • Watch Safari and Web Videos

Ask questions and discuss a variety of web development topics with Apple engineers and other developers.

  • Apple Developer Forums

Featured web technologies

Safari extensions.

Safari extensions are a powerful way to add new features to Safari. They are built in Xcode with web technologies, such as HTML5, CSS3, and JavaScript and powerful native APIs. Now you can distribute and sell them through the App Store on Mac, iPhone and iPad.

  • Meet Safari Web Extensions on iOS
  • Explore Safari Web Extension improvements
  • Converting a Web Extension for Safari
  • Creating a Content Blocker
  • Submit Your Extension

Universal links

Seamlessly link to content within your app or on your website in iOS, iPadOS, and macOS. With universal links, you can always give users the most integrated mobile experience, even when your app isn’t installed on their device.

  • Universal Links

Smart App Banners

Make it easy for people to discover and download your app using iOS, iPadOS, and macOS. With Safari Smart App Banners, you can display a banner that provides a direct link to your app on the App Store, or opens the app if the user already has it installed. Smart App Banners integrate seamlessly and are easy to implement.

  • Promoting Apps with Smart App Banners

HTTP Live Streaming (HLS)

Deliver streaming media to apps on iOS and iPadOS or HTML5-based websites using an ordinary web server.

  • HTTP Live Streaming

Safari iCloud Keychain

Easily create more secure logins for users in iOS 15, iPadOS 15, and macOS Monterey or later using iCloud Keychain verification codes. Take advantage of verification codes, AutoFill, iCloud Keychain sync, and two-tap setup to simplify the multistep sign-in process.

  • Secure login with iCloud Keychain verification codes
  • Securing Logins with iCloud Keychain Verification Codes
  • Safari Push Notifications

Use the Apple Push Notifications Service to send notifications to your website vistors, right on their Mac desktop — even when Safari isn’t running. These notifications display your website icon and notification text, which people can click to go right to your website.

  • Certificates, Identifiers & Profiles

Introduced by Apple, WebKit is the most advanced rendering engine, drawing the web pages in Safari on iOS, iPadOS, and macOS.

  • WebKit Open Source Project

Write automated tests to exercise web content in Safari to ensure a good user experience, and run those same tests against other browsers with a WebDriver-compliant driver.

  • macOS WebDriver Commands for Safari 11.1 and earlier
  • macOS WebDriver Commands for Safari 12 and later
  • About WebDriver for Safari
  • Testing with WebDriver in Safari
  • How to Login
  • Use Teams on the web
  • Join a meeting in Teams
  • Join without a Teams account
  • Join on a second device
  • Join as a view-only attendee
  • Join a breakout room
  • Join from Google
  • Schedule a meeting in Teams
  • Schedule from Outlook
  • Schedule from Google
  • Schedule with registration
  • Instant meeting
  • Add a dial-in number
  • See all your meetings
  • Invite people
  • Meeting roles
  • Add co-organizers
  • Hide attendee names
  • Tips for large Teams meeting
  • Lock a meeting
  • End a meeting
  • Manage your calendar
  • Meeting controls
  • Prepare in a green room
  • Share content
  • Share slides
  • Share sound
  • Apply video filters
  • Mute and unmute
  • Spotlight a video
  • Multitasking
  • Raise your hand
  • Live reactions
  • Take meeting notes
  • Customize your view
  • Laser pointer
  • Cast from a desktop
  • Use a green screen
  • Join as an avatar
  • Customize your avatar
  • Use emotes, gestures, and more
  • Get started with immersive spaces
  • Use in-meeting controls
  • Spatial audio
  • Overview of Microsoft Teams Premium
  • Intelligent productivity
  • Advanced meeting protection
  • Engaging event experiences
  • Change your background
  • Meeting themes
  • Audio settings
  • Manage attendee audio and video
  • Reduce background noise
  • Voice isolation in Teams
  • Mute notifications
  • Use breakout rooms
  • Live transcription
  • Language interpretation
  • Live captions
  • End-to-end encryption
  • Presenter modes
  • Call and meeting quality
  • Meeting attendance reports
  • Using the lobby
  • Meeting options
  • Record a meeting
  • Meeting recap
  • Play and share a meeting recording
  • Delete a recording
  • Edit or delete a transcript
  • Switch to town halls
  • Get started
  • Schedule a live event
  • Invite attendees
  • organizer checklist
  • For tier 1 events
  • Produce a live event
  • Produce a live event with Teams Encoder
  • Best practices
  • Moderate a Q&A
  • Allow anonymous presenters
  • Attendee engagement report
  • Recording and reports
  • Attend a live event in Teams
  • Participate in a Q&A
  • Use live captions
  • Schedule a webinar
  • Customize a webinar
  • Publicize a webinar
  • Manage webinar registration
  • Manage what attendees see
  • Change webinar details
  • Manage webinar emails
  • Cancel a webinar
  • Manage webinar recordings
  • Webinar attendance report
  • Get started with town hall
  • Attend a town hall
  • Schedule a town hall
  • Customize a town hall
  • Host a town hall
  • Use RTMP-In
  • Town hall insights
  • Manage town hall recordings
  • Cancel a town hall
  • Can't join a meeting
  • Camera isn't working
  • Microphone isn't working
  • My speaker isn’t working
  • Breakout rooms issues
  • Immersive spaces issues
  • Meetings keep dropping

safari open url

Use Microsoft Teams on the web

Note:  Microsoft Teams doesn't support Internet Explorer 11.  Learn more . Internet Explorer 11 will remain a supported browser. Internet Explorer 11 is a component of the Windows operating system and follows the Lifecycle Policy for the product on which it is installed.

Find Teams on the web at https://teams.microsoft.com .

To use Teams, you need a Microsoft 365 account with a Business or Enterprise Microsoft 365 license plan. For more information, see How do I get access to Microsoft Teams?

For information about supported browsers for Teams on the web, see  Web clients for Microsoft Teams .

Teams for web isn't currently supported on mobile devices. To use Teams on your mobile device, download the mobile app.

Facebook

Need more help?

Want more options.

Explore subscription benefits, browse training courses, learn how to secure your device, and more.

safari open url

Microsoft 365 subscription benefits

safari open url

Microsoft 365 training

safari open url

Microsoft security

safari open url

Accessibility center

Communities help you ask and answer questions, give feedback, and hear from experts with rich knowledge.

safari open url

Ask the Microsoft Community

safari open url

Microsoft Tech Community

safari open url

Windows Insiders

Microsoft 365 Insiders

Was this information helpful?

Thank you for your feedback.

Safari User Guide

  • Get started
  • Go to a website
  • Bookmark web pages to revisit
  • See your favourite websites
  • Use tabs for web pages
  • Import bookmarks and passwords
  • Pay with Apple Pay
  • Autofill credit card info
  • View links from friends
  • Keep a Reading List
  • Hide ads when reading
  • Translate a web page
  • Download items from the web
  • Add passes to Wallet
  • Save part or all of a web page
  • Print or create a PDF of a web page
  • Interact with text in a picture
  • Change your home page
  • Customise a start page
  • Create a profile
  • Block pop-ups
  • Make Safari your default web browser
  • Hide your email address
  • Manage cookies
  • Clear your browsing history
  • Browse privately
  • Prevent cross-site tracking
  • See who tried to track you
  • Change Safari settings
  • Keyboard and other shortcuts

safari open url

Go to a website using Safari on Mac

With Safari, it’s easy to get to the websites you want.

The Safari Smart Search field, where you can enter a website’s name or URL.

Open Safari for me

As you type, Safari Suggestions appear.

Pick a suggestion, or press Return to go directly to the address you typed.

Adobe Acrobat Learn & Support

Learn  what's new  in Acrobat!

Get Started

Download, find membership help, and learn the basics.

Find tutorials from novice to expert to help you expand your skills.

Get quick answers and step-by-step instructions.

Troubleshooting & help

Get help  downloading and installing  Acrobat, Acrobat 2020, 2017, Acrobat Reader, and more, along with common installation and troubleshooting issues.

See how to  uninstall and reinstall  Acrobat on Windows or macOS, as a trial, and on a second computer.

Your individual Acrobat license lets you  install Acrobat on more than one computer , and activate (sign in) on up to two computers.

Fix errors with your Adobe apps  if you received an error code or number, or get help with common  Acrobat installation errors and solutions .

Still need help? Find more download and install solutions . 

Get to know the Acrobat interface . Learn how the Acrobat Tool Center makes it easy to find the right tool and complete almost any task with your PDFs.

Many factors can prevent a PDF from opening. To get to the root of the problem, see  Can't open PDF .

Many factors can prevent you from editing a PDF. For information about how to edit a PDF, see  Edit PDF help hub page .

Windows 10 uses Microsoft Edge to open PDFs. Learn how to  make Acrobat or Reader the default owner of PDFs  instead.

Sign in to your  Adobe account . Under the  Password  section, select  Change  for C urrent Password , and then follow the onscreen instructions.

Forgot your password?  Learn how to  reset it .

Follow these  Update your credit card and billing information .

Converting your trial to a paid membership is easy. Follow these step-by-step instructions to  upgrade and start your membership .

Learn how to  cancel your subscription  and  understand the Adobe subscription terms .

Still need help? Find more  account, billing, and plan answers .

Ask questions and get answers from experts.

Ask now >

Acrobat subforums

Installing, Updating, & Using Acrobat

Document Cloud PDF services

Creating PDFs

Related Apps & Services

Document Cloud

Acrobat Reader

Adobe Acrobat Sign

Adobe Acrobat Sign - Mobile

Share this page

Language Navigation

IMAGES

  1. How to Show Full Website URL in iPhone Safari

    safari open url

  2. How to open Safari links in new tabs on iPhone, iPad, and Mac

    safari open url

  3. How to Preview a Link URL in Safari for iPhone & iPad Before Opening It

    safari open url

  4. HOW TO OPEN LINKS IN SAFARI || USING SAFARI WEB VIEW IN SWIFT 3

    safari open url

  5. How to automatically show the full URL in Safari

    safari open url

  6. Browse the web using Safari on iPhone

    safari open url

VIDEO

  1. Drag & drop a Safari URL

  2. How to Open URL with the Interactivity Feature

  3. Close all Open Safari Browser Tabs at Once in iPhone

  4. Как в Safari на iPhone открыть ссылку не покидая страницы. iPhone ссылки Safari фоновый режим

  5. Как открывать ссылки из браузера в нужном приложении на Андроид

  6. How to Copy Link or URL on Safari

COMMENTS

  1. Intro to URL schemes in Shortcuts on iPhone or iPad

    Intro to URL schemes in Shortcuts on iPhone or iPad. You can use URL schemes in Shortcuts. A URL scheme is the part of a link that specifies the type of application your device uses to open a URL. Many apps support URL schemes: FaceTime uses URL schemes to place calls when a URL starting with facetime:// is opened, just like Safari handles URLs ...

  2. safari

    Link opens in a link related app (e.g. The Guardian app for a theguardian.com link) Link opens in Safari, either (a) with or (b) without a suggestion to open in a link-related app; Link opens in Safari then launches a link related app (without navigating to or using the link to display content) and then bounces back to Safari again

  3. How to Copy URLs of All Open Tabs in Safari

    First, launch the Safari browser on your iPhone or iPad and open all the websites whose addresses you want to copy. On an iPad, tap the tabs button (four squares) or the plus ("+") button depending on your tab bar layout. On an iPhone, tap the "Tabs" button (overlapping squares) in the lower-right corner. All the open tabs will appear as a grid ...

  4. How to Preview Safari Links before Opening on iPhone ...

    First, open the Safari app on your Mac. Click the "View" section in the menu bar and choose the "Show Status Bar" option. With this enabled, when you hover over any link, you will see its full URL address in the status bar in the bottom-left corner of the page. If you ever want to disable this link preview, click View > Hide Status Bar in the ...

  5. Force URL link to open with a specific browser

    It lets you easily create rules to make certain URLs open in a specific browser. Open the app settings, go to the "Rules" tab, click "+", select "Firefox" in the "Open in" dropdown, add a URL matcher that matches the URL you want to open in Firefox, and then click "Save". Share. Improve this answer.

  6. How to use Safari on a Mac

    Open the offending website. Click on Safari > Settings for This Website (or right-click the URL box and select Settings for This Website). You will see a pop-up window with the option Auto-Play ...

  7. How to open web links in Safari

    SwiftUI gives us a dedicated Link view that looks like a button but opens a URL in Safari when pressed. It's easy enough to use - just give it a title for the button, plus a destination URL to show, like this: ... you can open a URL from code by using the openURL environment key, like this: struct ContentView: View { @Environment(\.openURL ...

  8. How to open a http page in safari?

    Safari can't open the page "https://..." because Safari can't establish a secure connection to the server "...". Is there a way to open such a page nevertheless in Safari? This is for testing purposes only, (to test the rendering of this non-public page, visible only through VPN), so there is no security concern?

  9. Safari

    Safari. Blazing fast. Incredibly private. Safari is the best way to experience the internet on all your Apple devices. It brings robust customization options, powerful privacy protections, and optimizes battery life — so you can browse how you like, when you like. And when it comes to speed, it's the world's fastest browser. 1.

  10. How can I open a url in a new window on safari iphone

    If you want to know how to open a url in a new window on safari iphone, you can find the answer in this Stack Overflow question. You will learn about the difference between window.open() and location.href, and how to use the target attribute or the rel attribute to control the behavior of the links. This question has several useful answers and comments from experienced developers.

  11. Browse the web using Safari on iPad

    Use Split View to open two Safari pages side-by side. Open a blank page in Split View: Touch and hold , then tap New Window. Open a link in Split View: Touch and hold the link, then tap Open in New Window. Move a window to the other side of Split View: Touch and hold at the top of the window, then drag left or right. Close tabs in a Split View window: Touch and hold .

  12. Window: open() method

    The Window interface's open() method takes a URL as a parameter, and loads the resource it identifies into a new or existing tab or window. The target parameter determines which window or tab to load the resource into, and the windowFeatures parameter can be used to control to open a new popup with minimal UI features and control its size and position. ...

  13. How to open a URL in Safari

    If you want the user to exit your app and show a website in Safari, it's just one line of code in Swift. I'll make it three here because I'll create the URL in the code too, then safely unwrap it: if let url = URL(string: "https://www.hackingwithswift.com") { UIApplication.shared.open(url) } It's worth adding that you have the option of using ...

  14. Open an URL in Safari with Private Browsing

    In Terminal, run the following compound command: touch safari; open -e safari; chmod +x safari. Copy and paste the example AppleScript code, shown further below, into the opened safari document, then save it. You should then move the safari shell script to a directory located within the shell's PATH. I moved it to /usr/local/bin, e.g,:

  15. How to fix "Safari can't establish a secure connection" on Mac

    There might be a few reasons for why Safari can't open a particular page online. Every time you load a URL, Safari checks that the data on the other end is valid and secure. ... You might already know that the domain name you put in as a URL isn't actually what the internet uses to connect to different websites. Instead, all websites have ...

  16. Resources

    Safari iCloud Keychain. Easily create more secure logins for users in iOS 15, iPadOS 15, and macOS Monterey or later using iCloud Keychain verification codes. Take advantage of verification codes, AutoFill, iCloud Keychain sync, and two-tap setup to simplify the multistep sign-in process. Secure login with iCloud Keychain verification codes

  17. Use Microsoft Teams on the web

    Find Teams on the web at https://teams.microsoft.com.. To use Teams, you need a Microsoft 365 account with a Business or Enterprise Microsoft 365 license plan. For more information, see How do I get access to Microsoft Teams?. For information about supported browsers for Teams on the web, see Web clients for Microsoft Teams.

  18. Open URL in new Safari tab with AppleScript

    tell application "Safari" try display dialog "Website URL" default answer "" buttons {"OK", "Annuler"} default button 1 set theURL to text returned of result set netProto to "https://" if theURL contains netProto then set the URL of (make new tab in window 1) to theURL else set the URL of (make new tab in window 1) to netProto & theURL end if ...

  19. Go to a website using Safari on Mac

    With Safari, it's easy to get to the websites you want. In the Safari app on your Mac, enter the website's name or URL in the Smart Search field. As you type, Safari Suggestions appear. Pick a suggestion, or press Return to go directly to the address you typed. In Safari on your Mac, get to the websites you want, organise your favourites ...

  20. Adobe Acrobat Learn & Support

    Get started with Adobe Acrobat. Find tutorials, the user guide, answers to common questions, and help from the community forum.