Twingly Blog Search Language

Introduction

The Twingly search language provides a powerful set of tools to be used when querying the public blog search and the Blog Search API.

Searching for blog posts using keyword

Search all fields for the given keywords.

# search for posts containing the words twingly and blog
twingly blog

# search for posts containing the phrase "I love blogging"
"I love blogging"

# search for posts containing the words twingly or blog
twingly OR blog

# search for posts containing the words twingly and either blog or blogs
twingly AND (blog OR blogs)

# search for posts containing the word twingly but not the word blog
twingly -blog

Searching for Chinese, Japanese and Korean characters

Chinese, Japanese and Korean (CJK) characters are handled as individual words. To search for multi-character words, the word needs to be quoted as a phrase.

# Search for posts containing containing 東京 (Tokyo).
"東京"

# Search for posts containing 東 (Eastern) and 京 (Capital).
# For example a post mentioning both "東大" Tokyo University and "京都市" (Kyoto) will match.
東京

Limiting search to a specific field

By default all searchable fields are queried, you can limit the search to specific fields.

# search just the text
fields:summary twingly

# search the text and the title
fields:summary|title twingly

The supported arguments to fields are:

Searching for blog posts linking to specific sites

You can search for blog posts that link to specific pages. Note that URLs are normalized in the index, check out the URL normalization section.

# search for posts that link to any page on twingly.com
link:twingly.com

# search for posts that link a specific page on twingly.com
link:twingly.com/ping

# search for posts that link to any page on twingly.com *and* techcrunch.com
link:twingly.com,techcrunch.com

# search for posts that link to any page on twingly.com *or* techcrunch.com
link:twingly.com|techcrunch.com

# search for posts linking to twingly.com but not pingomatic.com
link:twingly.com -link:pingomatic.com

Note that the link: and -link: operators are computationally expensive. Excessive use of them may slow down the query considerably or even result in a query timeout.

Searching for blog posts on a specific domain

You can search for blog posts on a specific domain, including subdomains. Note that URLs are normalized in the index, check out the URL normalization section.

# search for blog posts on twingly.com, including blog.twingly.com
site:twingly.com

# search for blog posts on several domains
site:twingly.com|primelabs.se

# search for blog posts mentioning twingly but not on twingly.com
twingly -site:twingly.com

Note that the site: and -site: operators are computationally expensive. Excessive use of them may slow down the query considerably or even result in a query timeout.

Searching for blog posts on a specific blog

You can search for blog posts on a specific blog. Note that URLs are normalized in the index, check out the URL normalization section.

# search for blog posts on blog.twingly.com
blog:blog.twingly.com

# search for blog posts on multiple blogs
blog:blog.twingly.com|roslingsblogger.blogspot.com

# search for blog posts mentioning twingly but not on blog.twingly.com
twingly -blog:twingly.com

Searching for blog posts written in a specific language

You can search for blog posts written in a specific language.

# search for blog posts written in Swedish
lang:sv

# search for blog posts written in Swedish or Finnish
lang:sv|fi

List of all supported languages.

Searching for blog posts from a specific location

You can search for blog posts from a specific location.

# search for blog posts from Sweden
location:se

# search for blog posts from in Sweden or Finland
location:se|fi

List of all supported locations.

Searching for blog posts tagged with a specific tag

You can search for blog posts with specific tags.

# search for blog posts with the tag election
tag:election

# search for blog posts with the tags election *and* obama
tag:election,obama

# search for blog posts with the tags election, sport *or* fashion
tag:election|sport|fashion

# search for blog posts with the tag obama but not election
tag:obama -tag:election

Searching for blog posts written by a specific author

# search for blog posts with an author named Isabella
author:isabella

# search for blog posts with an author named Isabella but not "Isabella Wight"
author:isabella -author:wight

Searching for blog posts within a given time span

The default is to search in posts published at any time.

You can search for posts that were published within the last 24 hours.

tspan:24h

The supported arguments to tspan are:

In addition to the tspan parameter you can perform explicit searches on creation (indexed) time or published time.

# search for posts created (indexed) after 2016-01-16
start-created:"2016-01-16"

# search for posts created (indexed) between 2015-12-01 and 2015-12-02
start-created:"2015-12-01" end-created:"2015-12-02"

# search for posts published between 2015-12-01 02:00:00 and 2015-12-01 03:00:00
start-date:"2015-12-01 02:00:00" end-date:"2015-12-01 03:00:00"

Note that using tspan in the same query as start-created, end-created, start-date or end-date is not supported and will yield unexpected results.

Sorting the results

You can sort the blog posts in multiple ways.

# sort by published
sort:published

# sort by inlinks
sort:inlinks

The supported arguments to sort are:

Sort order

You can specify the sort order.

# ascending
sort-order:asc

# descending
sort-order:desc

Supported languages

To query a specific language, use the the two-letter ISO 639-1 code.

Language Code Remarks
Afrikaans af  
Arabic ar  
Bulgarian bg  
Bengali bn  
Catalan ca  
Czech cs  
Welsh cy  
Danish da  
German de  
Greek el  
English en  
Spanish es  
Estonian et  
Persian fa  
Finnish fi  
French fr  
Gujarati gu  
Hebrew he  
Hindi hi  
Croatian hr  
Hungarian hu  
Indonesian id  
Icelandic is  
Italian it  
Japanese ja  
Georgian ka  
Kannada kn  
Korean ko  
Lithuanian lt  
Macedonian mk  
Malayalam ml  
Marathi mr  
Nepali ne  
Dutch nl  
Norwegian no  
Punjabi pa  
Polish pl  
Portuguese pt  
Romanian ro  
Russian ru  
Slovak sk  
Slovenian sl  
Somali so  
Albanian sq  
Serbian sr Only the Cyrillic alphabet is supported
Swedish sv  
Swahili sw  
Tamil ta  
Telugu te  
Thai th  
Tagalog tl  
Turkish tr  
Ukrainian uk  
Urdu ur  
Vietnamese vi  
Chinese zh Includes both simplified and traditional Chinese

Supported locations

To query a specific location, use the the two-letter ISO 3166-1 alpha-2 format code.

Location Code Remarks
Andorra ad  
United Arab Emirates ae  
Afghanistan af  
Antigua and Barbuda ag  
Anguilla ai  
Albania al  
Armenia am  
Angola ao  
Antarctica aq  
Argentina ar  
American Samoa as  
Austria at  
Australia au  
Aruba aw  
Aland Islands ax  
Azerbaijan az  
Bosnia and Herzegovina ba  
Barbados bb  
Bangladesh bd  
Belgium be  
Burkina Faso bf  
Bulgaria bg  
Bahrain bh  
Burundi bi  
Benin bj  
Saint Barth bl  
Bermuda bm  
Brunei Darussalam bn  
Bolivia bo  
Bonaire bq  
Brazil br  
Bahamas bs  
Bhutan bt  
Bouvet Island bv  
Botswana bw  
Belarus by  
Belize bz  
Canada ca  
Cocos cc  
Democratic Republic of Congo cd  
Central African Republic cf  
Congo cg  
Switzerland ch  
Ivory Coast ci  
Cook Islands ck  
Chile cl  
Cameroon cm  
China cn  
Colombia co  
Costa Rica cr  
Cuba cu  
Cape Verde cv  
Curacao cw  
Christmas Island cx  
Cyprus cy  
Czech Republic cz  
Germany de  
Djibouti dj  
Denmark dk  
Dominica dm  
Dominican Republic do  
Algeria dz  
Ecuador ec  
Estonia ee  
Egypt eg  
Western Sahara eh  
Eritrea er  
Spain es  
Ethiopia et  
Finland fi  
Fiji fj  
Falkland Islands fk  
Micronesia fm  
Faroe Islands fo  
France fr  
Gabon ga  
United Kingdom gb  
Grenada gd  
Georgia ge  
French Guiana gf  
Guernsey gg  
Ghana gh  
Gibraltar gi  
Greenland gl  
Gambia gm  
Guinea gn  
Guadeloupe gp  
Equatorial Guinea gq  
Greece gr  
South Georgia and the South Sandwich Islands gs  
Guatemala gt  
Guam gu  
Guinea Bissau gw  
Guyana gy  
Hong Kong hk  
Heard Island and Mcdonald Islands hm  
Honduras hn  
Croatia hr  
Haiti ht  
Hungary hu  
Indonesia id  
Ireland ie  
Israel il  
Isle of Man im  
India in  
British Indian Ocean Territory io  
Iraq iq  
Iran ir  
Iceland is  
Italy it  
Jersey je  
Jamaica jm  
Jordan jo  
Japan jp  
Kenya ke  
Kyrgyzstan kg  
Cambodia kh  
Kiribati ki  
Comoros km  
Saint Kitts and Nevis kn  
Democratic Peoples Republic of Korea kp  
Republic of Korea kr  
Kuwait kw  
Cayman Islands ky  
Kazakhstan kz  
Lao Peoples Democratic Republic la  
Lebanon lb  
Saint Lucia lc  
Liechtenstein li  
Sri Lanka lk  
Liberia lr  
Lesotho ls  
Lithuania lt  
Luxembourg lu  
Latvia lv  
Libya ly  
Morocco ma  
Monaco mc  
Moldova md  
Montenegro me  
Saint Martin mf  
Madagascar mg  
Marshall Islands mh  
Macedonia mk  
Mali ml  
Myanmar mm  
Mongolia mn  
Macao mo  
Northern Mariana Islands mp  
Martinique mq  
Mauritania mr  
Montserrat ms  
Malta mt  
Mauritius mu  
Maldives mv  
Malawi mw  
Mexico mx  
Malaysia my  
Mozambique mz  
Namibia na  
New Caledonia nc  
Niger ne  
Norfolk Island nf  
Nigeria ng  
Nicaragua ni  
Netherlands nl  
Norway no  
Nepal np  
Nauru nr  
Niue nu  
New Zealand nz  
Oman om  
Panama pa  
Peru pe  
French Polynesia pf  
PapuaNewGuinea pg  
Philippines ph  
Pakistan pk  
Poland pl  
Saint Pierre and Miquelon pm  
Pitcairn pn  
PuertoRico pr  
Palestine ps  
Portugal pt  
Palau pw  
Paraguay py  
Qatar qa  
Reunion re  
Romania ro  
Serbia rs  
Russian Federation ru  
Rwanda rw  
Saudi Arabia sa  
Solomon Islands sb  
Seychelles sc  
Sudan sd  
Sweden se  
Singapore sg  
Saint Helena sh  
Slovenia si  
Svalbard and Jan Mayen sj  
Slovakia sk  
Sierra Leone sl  
SanMarino sm  
Senegal sn  
Somalia so  
Suriname sr  
SouthSudan ss  
Sao Tome and Principe st  
ElSalvador sv  
Sint Maarten sx  
Syrian Arab Republic sy  
Swaziland sz  
Turks and Caicos Islands tc  
Chad td  
French Southern Territories tf  
Togo tg  
Thailand th  
Tajikistan tj  
Tokelau tk  
Timor tl  
Turkmenistan tm  
Tunisia tn  
Tonga to  
Turkey tr  
Trinidad and Tobago tt  
Tuvalu tv  
Taiwan tw  
Tanzania tz  
Ukraine ua  
Uganda ug  
United States Minor Outlying Islands um  
United States us  
Uruguay uy  
Uzbekistan uz  
Holy See va  
Saint Vincent and the Grenadines vc  
Venezuela ve  
British Virgin Islands vg  
US Virgin Islands vi  
Vietnam vn  
Vanuatu vu  
Wallis and Futuna wf  
Samoa ws  
Yemen ye  
Mayotte yt  
South Africa za  
Zambia zm  
Zimbabwe zw  

URL normalization

Since a web resource can have multiple URLs, we apply some normalization to make the index more consistent. We do not normalize the query pattern, this normalization has to be done by the user for URL searches like link:, blog: and site:.

Domains

We add www. for all domains that only consists of a SLD and TLD.

https://twingly.com/ -> https://www.twingly.com/

For domains with a non-www subdomain, we remove www. if present.

https://www.blog.twingly.com/ -> https://blog.twingly.com/

Blogspot

Google introduced country specific TLDs for Blogspot early 2012. The result of this change is that the same blog will have different URLs dependening on which country you’re currently browsing the web in. In order to map blogspot posts to it’s blog we normalize blogspot.<TLD> to blogspot.com for all blogspot blogs.


Known issues


Documentation changelog