How hashtag matching works here
The pattern #[\w]+ captures a hash sign followed by one or more characters in [A-Za-z0-9_]. Tags stop at the first space, punctuation, emoji or accented character. So #spring, #travel2026 and #behind_the_scenes all match in full, while #café is captured as #caf because é is not in the ASCII word class.
A double hash ##bonus is read as a hash followed by #bonus; the leading # on its own is dropped because the pattern requires at least one word character after the hash. Hash-prefixed numeric tokens like #1 or #2026 match too.
Output is one tag per line in the order they appear, including the leading hash. Duplicates are kept; pipe the result through remove duplicate lines for a unique tag list.
How to use extract hashtags from text
- 1Paste the post, caption or message into the input panel.
- 2The output panel shows every hashtag, one per line.
- 3Click Copy to copy the list.
- 4Click Download to save it as a plain-text file.
- 5For unique tags only, send the result to remove duplicate lines.
Keyboard shortcuts
Drive TextResult without touching the mouse.
| Shortcut | Action |
|---|---|
| Ctrl F | Open the find & replace panel inside the input Plus |
| Ctrl Z | Undo the last input change |
| Ctrl Shift Z | Redo |
| Ctrl Shift Enter | Toggle fullscreen focus on the editor Plus |
| Esc | Close find & replace, or exit fullscreen |
| Ctrl K | Open the command palette to jump to any tool Plus |
| Ctrl S | Save current workflow draft Plus |
| Ctrl P | Run a saved workflow Plus |
What counts as a hashtag here
Hash followed by word characters
Letters A-Z a-z, digits 0-9 and underscore are accepted in the tag body. #travel, #travel2026 and #behind_the_scenes all match.
Stops at non-word characters
Spaces, punctuation, emoji and accented letters terminate the match. #café is captured as #caf; #tag! is captured as #tag.
Numeric-only tags allowed
#1, #2026 and #100days all match. The pattern does not require a leading letter.
Double-hash collapses
##bonus matches as #bonus. The first hash on its own is not a valid tag because the pattern needs at least one word character after the hash.
Order preserved, duplicates kept
Tags appear in source order. Duplicates are not removed; for a unique list pipe the output into remove duplicate lines.
Worked example
Notice #café stops at the accented letter and is captured as #caf. The duplicate #tag1 is kept; dedupe afterwards if you need unique tags only.
Loving the #spring vibes! #photography #naturelovers #travel2026 #behind_the_scenes #café gets clipped. #tag1 #tag1 (duplicate kept).
#spring #photography #naturelovers #travel2026 #behind_the_scenes #caf #tag1 #tag1
Settings reference
| Behaviour | Effect on output |
|---|---|
| Tag body characters | Letters A-Z a-z, digits 0-9, underscore. |
| Accented letters | Not in the word class. #café matches as #caf. |
| Emoji and punctuation | Terminate the match. #tag! gives #tag. |
| Numeric-only tags | Allowed. #1, #2026 match. |
| Double hash | Collapses. ##bonus gives #bonus. |
| Order and duplicates | Source order kept, duplicates kept. |
FAQ
Why does #café get clipped to #caf?
[\w], which is letters, digits and underscore only. Accented letters and other Unicode letters terminate the tag. To capture full Unicode tags, switch to extract regex matches with the pattern #[\p{L}\p{N}_]+ and the gu flag.Are emoji-only tags supported?
# followed by an emoji does not match. Emoji embedded mid-tag also terminate the tag at that point.Is the leading hash included in each match?
#. Strip them with find and replace if you want the bare tag bodies.