How to extract hashtags and mentions from text
Reusing the tag set from a post that performed well, or pulling every account named across a batch of comments, is tedious to do by eye. Paste the text and this tool returns hashtags and mentions as two separate lists, plus a table showing how many unique values there are and how often each one appears.
Detection uses Unicode character properties rather than the ASCII-only shorthand, so tags written in Korean, Japanese, Chinese or any accented Latin script are recognised alongside plain English ones. Digits and underscores are allowed inside a tag. Tags run together without spaces, the #coffee#dessert style common on Instagram, are also split apart correctly.
A mention is only counted when the at sign is not preceded by a letter, digit or dot, which keeps email addresses in the text out of the mention list. A trailing period is treated as punctuation and trimmed off. Deduplication, frequency sorting and whether to keep the leading symbol are all optional, and the two lists can be copied separately. The frequency table shows up to 100 rows. Everything runs inside your browser.
Frequently asked questions
Yes. Matching is based on Unicode character properties, so Korean, Japanese, Chinese and accented Latin tags are all picked up along with English ones.
No. An at sign preceded by a letter, digit or dot is not treated as a mention, so addresses inside the text are left out of the results.