Toolvito

Works on this device

Browser Bookmark Sorter

Open the bookmarks file that your browser exports (an HTML file such as bookmarks.html). The tool sorts the bookmarks in every folder by name, link or date added, finds links that are bookmarked more than once, and writes a new bookmarks file that you can import. The file is read on this device and is not uploaded.

Enter your values

Sorts the bookmarks of every folder by name, link or date added, and writes a new bookmarks file to import.

Your values

The HTML file that your browser exports, such as bookmarks.html, at most 32 MB. It is read on this device and is not uploaded.

The bookmarks bar and the other main folders stay where they are. Everything inside them is sorted.

Your values are worked out in this browser. They are not sent to a server.

Your result will show here

Fill in the values, then choose the button below them.

How to use the bookmark sorter

  1. Export your bookmarks from your browser as an HTML file. In Chrome and Edge it is in the bookmark manager menu (Export bookmarks). In Firefox it is under Manage bookmarks, Import and Backup, Export Bookmarks to HTML.
  2. Choose the file under Bookmarks file.
  3. Choose how to sort: by name, by link or by date added, and where folders go. By default the top level (such as the bookmarks bar) keeps its order and everything inside it is sorted.
  4. Choose Sort. Download the new file with Download file and import it in your browser. The table lists every folder and bookmark in the new order.
  5. To see links that are bookmarked more than once, choose Find duplicate bookmarks. Tick Remove the duplicates to get a file without the later copies.

How the file is read and sorted

  • The file is read as text by a small HTML reader. Nothing in it is run or loaded. A folder is an <H3> with the <DL> list after it, a bookmark is an <A HREF>, a separator is <HR>, and a <DD> after an item is its description.
  • Every attribute of a folder or a bookmark is kept as it was, such as ADD_DATE, LAST_MODIFIED, ICON and PERSONAL_TOOLBAR_FOLDER.
  • Name: compared in small letters, and a run of digits by its value, so "Soup 2" comes before "Soup 10".
  • Link: compared as written in the file, character by character.
  • Date added: the ADD_DATE of each item, which is seconds since 1 January 1970 (UTC). Items with no date go after the dated ones.
  • Items that sort the same keep their old order. A sorted folder has no separator lines, because they belong to the old order.

When two bookmarks are duplicates

  • By default two links are the same when the browser's URL class writes them the same: the host in small letters, no default port (:443 for https, :80 for http), and . and .. steps of the path worked out. So https://WWW.EXAMPLE.ORG/news and https://www.example.org/news are the same link.
  • Capital letters in the path and the query, and the part after #, still count. A link that is not http or https, such as a javascript: bookmarklet, must be written exactly the same.
  • When duplicates are removed, the first bookmark of each link in the file stays and later copies are taken out.

Worked example

The example file has the folder "Bookmarks bar" with "Zebra News", "apple guide", the folder "Recipes" (with "Soup 10" and "Soup 2"), a separator and "Zebra News again". Below the folder is "Shop & more".

Sorted by name with folders first, the bookmarks bar holds "Recipes" ("Soup 2", then "Soup 10"), then "apple guide", "Zebra News" and "Zebra News again". The separator is left out. The top level keeps its order. "Zebra News" and "Zebra News again" have the same link in standard form, so 1 link is in the file more than once.

Limits you should know

  • Only the Netscape bookmark HTML format is read. JSON backups (such as the Firefox .json backup) and the files inside the browser's profile folder are not read.
  • Importing the new file usually adds the bookmarks in a new folder. It does not replace or delete the bookmarks in your browser, so you may want to remove the old ones yourself. Keep a copy of your own file.
  • The tool does not open the links, so it cannot tell whether a link still works or whether two different links lead to the same page.
  • Files of at most 32 MB.
  • To sort or clean a plain list of links, use the URL List Organizer.

Related tools