Datatypes

Hashtag

ID hashtag

DatatypeNot PIIcategoricalDraft

This record is a draft: it has not been reviewed yet and may be incomplete or wrong. Do not rely on it for compliance decisions. Help improve it (see CONTRIBUTING.md).

Keyword marked with the # sign in social media posts and messages, used to group posts on one topic. It may contain letters of any script, digits and underscores, but no spaces or punctuation. X (Twitter) and Mastodon do not link a tag made only of digits, so the regexp requires at least one letter. Wikidata property P2572 stores hashtags without the # sign; the regexp requires it, because without it a hashtag is an ordinary word. Python matches letters of all scripts; the browser regexp engine matches only Latin letters, and neither matches combining vowel signs of Indic scripts.

Categories
Texts and articles, Internet
Countries
Global (not tied to a country)
Languages
Common to most languages
Wikidata
P2572
Quality
90/100 · missing: detector coverage
Metacrafter rules
no detection rule yet
Supported by tools
no tool record lists this type yet

Regular expression

^#\w*[^\W\d_]\w*$

Python re syntax.

Examples

ValueDescription
#ww2World War II (Wikidata P2572)
#спортSport, in Russian (Wikidata P2572)
#16 invalidDigits only, not linked as a hashtag
#open data invalidA space ends the hashtag

Translations

LanguageNameDescription
RussianХештегКлючевое слово со знаком # в публикациях социальных сетей. Состоит из букв, цифр и знаков подчёркивания, без пробелов; тег только из цифр не считается хештегом.

Sources

Use this record