1. Home
  2. Developer
  3. Link Extractor

Link Extractor

Collect links and image URLs from page source, sort internal and external, save CSV.

Runs in your browser · No upload
The code is read only inside this browser.
Used to resolve relative paths and to tell internal links from external ones. If empty, the canonical, og:url or base tag in the source is used.

Base URL: https://www.example.com/guide/ (from canonical)

Extracted
12
Shown
12
Internal
5
External
4
In-page (#)
1
Email
1
Phone
1
What to extract
Class
Extracted
#TypeURLClassText / altrel / target
1link (CSS, icons...)https://www.example.com/guide/Internalcanonicalcanonical
2link (CSS, icons...)https://www.example.com/css/site.cssInternalstylesheetstylesheet
3Scriptshttps://cdn.jsdelivr.example/lib.jsExternal
4Links (a)https://www.example.com/InternalHome
5Links (a)https://www.example.com/guide/startInternalGetting started
6Links (a)#faqIn-page (#)FAQ
7Links (a)https://developer.example.org/docsExternalofficial docsnofollow | _blank
8Links (a)https://shop.example.net/item?id=7ExternalRecommended itemsponsored
9Links (a)mailto:help@example.comEmailEmail us
10Links (a)tel:+8225551234PhoneCall us
11Imageshttps://www.example.com/img/hero.jpgInternalHero image
12iframeshttps://video.example.net/embed/1ExternalIntro video

How to use

  1. On the page whose links you want, press Ctrl+U (Option+Command+U on a Mac) to open view-source, copy everything and paste it into the box.
  2. Type the page’s address in Site URL to turn relative paths such as /guide or ../img/a.png into full URLs and make the internal and external split accurate. If you leave it empty, the tool looks for a base in the source: the canonical, then og:url, then <base>.
  3. Use the What to extract and Class checkboxes to keep only what you need, then turn on sorting, search or unique URLs.
  4. Take the result with Copy URLs, Text or Download CSV. The table draws at most 500 rows, but copy and download include everything that passes the filters.

What it extracts

Type Tags and attributes read
Links href of a (with the link text, rel and target)
Images src, data-src and the first srcset URL of img, and srcset of source inside picture
link href of link (stylesheets, icons, canonical and so on)
Scripts src of script
iframes src of iframe
Video / audio src of video, audio and source
area href of image-map area

Tags inside comments and links with an empty href are skipped.

Class Rule
Internal A relative path, or the same domain as the site URL (www. is ignored)
External Any other domain. blog.example.com is a subdomain of example.com but counts as a different domain
In-page Starts with #, like #faq
Email, phone mailto:, tel:
javascript, data Starts with javascript: or data:
Other ftp:, sms: and other schemes

For example, with the site URL https://example.com/dir/page, /a resolves to https://example.com/a and ../d to https://example.com/d, and both are internal.

Reading the rel attribute

Links carrying nofollow, sponsored or ugc show the value in the rel column, and ticking nofollow only gathers just those. It is handy for checking that you did not forget sponsored or nofollow on advertising and affiliate links. The tool shows attributes; it does not test whether a link actually works (broken links).

Good to know

  • Links created by JavaScript after the page loads may be absent from view-source. In that case copy the <html> element from the Elements tab of the developer tools.
  • Unique mode merges items whose resolved URL is the same and shows a count such as “(x3)”.
  • In CSV, cells starting with =, +, - or @ get a leading apostrophe so a spreadsheet will not run them as formulas.
  • Tools that pair well: the Meta Tag Checker, the Heading Checker, the URL Encoder / Decoder for special characters in addresses, and the HTML Beautify / Minify to make source easier to read.

Frequently asked questions

No. The tool does not fetch pages by address. It reads only the HTML copied from view-source. The Site URL box is just the base for resolving relative paths.

Same domain as the site URL means internal, anything else is external. www.example.com and example.com count as the same site. If the site URL is unknown, only relative paths are classed as internal.

Are image URLs extracted too?

Yes: the src of img, data-src used for lazy loading, and the first srcset URL. To see only those, leave just images ticked under What to extract.

The CSV looks garbled in Excel.

The CSV is saved as UTF-8 with a byte order mark so Excel usually opens it correctly. If it still looks garbled, use the data import option and set the file origin to UTF-8.

Where does the pasted source go?

The text you enter is processed only in your browser and never sent to a server.

Can't find the tool you need?

Tell us what you want to do. We build the most requested tools first.