php keyword rank checker

php keyword rank checker

Free php keyword rank checker scripts available:

Get code and script of keyword rank checker in php if you want google keyword position checker api then check below, now a days people dont want to invest in ads of google so for that they need tools and free keyword rank checker script to check their keyword rank as per analysis they do on page seo and off page seo as per their need here check php keyword rank checker and also lots of seo tools we are updating with their name and work and also you can able to search your website prominent keywords on this page also you can check here , now a days people only need to know how seo work but here we have lots of strateggy and also we will give you php code from which you can check your keyword rank by adding code in your website also investing in ads will be waste of time if you will have proper content which should be unique and also you have all the data which users are searching on your page will make you rank higher and highrer also you can see this page is listed on first google page only because we are having content which is complete package of users needs


The Google SERP Checker Source Code:

People looking for  php keyword rank checker code or we can say google keyword position checker api, google rank checker script and they want to add this to their website by which their visitor can able to check keyword ranking on their website or portal now a days google ranking checker api you can get in different different technology like php,html and css ,python ,Java, JavaScript, Swift,C++, C#, R, Golang (Go)

When visitor search query on google like  google keyword position checker script or google keyword rank checker script or google keyword ranking api in php or google keyword position checker php script they usually code of this but here we are providing you all kind of code related to that please follow our link to get codes which is related to different different programming language 

 This code will use for all links or keywords given below here is the code in php only 

google rank checker  Afghanistan
google rank checker Albania
google rank checker Algeria
google rank checker American Samoa
google rank checker Andorra
google rank checker Angola
google rank checker Anguilla
google rank checker Antarctica
google rank checker Antigua And Barbuda
google rank checker Argentina
google rank checker Armenia
google rank checker Aruba
google rank checker Australia
google rank checker Austria
google rank checker Azerbaijan
google rank checker Bahamas The
google rank checker Bahrain
google rank checker Bangladesh
google rank checker Barbados
google rank checker Belarus
google rank checker Belgium
google rank checker Belize
google rank checker Benin
google rank checker Bermuda
google rank checker Bhutan
google rank checker Bolivia
google rank checker Bosnia and Herzegovina
google rank checker Botswana
google rank checker Bouvet Island
google rank checker Brazil
google rank checker British Indian Ocean Territory
google rank checker Brunei
google rank checker Bulgaria
google rank checker Burkina Faso
google rank checker Burundi
google rank checker Cambodia
google rank checker Cameroon
google rank checker Canada
google rank checker Cape Verde
google rank checker Cayman Islands
google rank checker Central African Republic
google rank checker Chad
google rank checker Chile
google rank checker China
google rank checker Christmas Island
google rank checker Cocos (Keeling) Islands
google rank checker Colombia
google rank checker Comoros
google rank checker Republic Of The Congo
google rank checker Democratic Republic Of The Congo
google rank checker Cook Islands
google rank checker Costa Rica
google rank checker Cote D'Ivoire (Ivory Coast)
google rank checker Croatia (Hrvatska)
google rank checker Cuba
google rank checker Cyprus
google rank checker Czech Republic
google rank checker Denmark
google rank checker Djibouti
google rank checker Dominica
google rank checker Dominican Republic
google rank checker East Timor
google rank checker Ecuador
google rank checker Egypt
google rank checker El Salvador
google rank checker Equatorial Guinea
google rank checker Eritrea
google rank checker Estonia
google rank checker Ethiopia
google rank checker External Territories of Australia
google rank checker Falkland Islands
google rank checker Faroe Islands
google rank checker Fiji Islands
google rank checker Finland
google rank checker France
google rank checker French Guiana
google rank checker French Polynesia
google rank checker French Southern Territories
google rank checker Gabon
google rank checker Gambia The
google rank checker Georgia
google rank checker Germany
google rank checker Ghana
google rank checker Gibraltar
google rank checker Greece
google rank checker Greenland
google rank checker Grenada
google rank checker Guadeloupe
google rank checker Guam
google rank checker Guatemala
google rank checker Guernsey and Alderney
google rank checker Guinea
google rank checker Guinea-Bissau
google rank checker Guyana
google rank checker Haiti
google rank checker Heard and McDonald Islands
google rank checker Honduras
google rank checker Hong Kong S.A.R.
google rank checker Hungary
google rank checker Iceland
google rank checker India
google rank checker Indonesia
google rank checker Iran
google rank checker Iraq
google rank checker Ireland
google rank checker Israel
google rank checker Italy
google rank checker Jamaica
google rank checker Japan
google rank checker Jersey
google rank checker Jordan
google rank checker Kazakhstan
google rank checker Kenya
google rank checker Kiribati
google rank checker Korea North
google rank checker Korea South
google rank checker Kuwait
google rank checker Kyrgyzstan
google rank checker Laos
google rank checker Latvia
google rank checker Lebanon
google rank checker Lesotho
google rank checker Liberia
google rank checker Libya
google rank checker Liechtenstein
google rank checker Lithuania
google rank checker Luxembourg
google rank checker Macau S.A.R.
google rank checker Macedonia
google rank checker Madagascar
google rank checker Malawi
google rank checker Malaysia
google rank checker Maldives
google rank checker Mali
google rank checker Malta
google rank checker Man (Isle of)
google rank checker Marshall Islands
google rank checker Martinique
google rank checker Mauritania
google rank checker Mauritius
google rank checker Mayotte
google rank checker Mexico
google rank checker Micronesia
google rank checker Moldova
google rank checker Monaco
google rank checker Mongolia
google rank checker Montserrat
google rank checker Morocco
google rank checker Mozambique
google rank checker Myanmar
google rank checker Namibia
google rank checker Nauru
google rank checker Nepal
google rank checker Netherlands Antilles
google rank checker Netherlands The
google rank checker New Caledonia
google rank checker New Zealand
google rank checker Nicaragua
google rank checker Niger
google rank checker Nigeria
google rank checker Niue
google rank checker Norfolk Island
google rank checker Northern Mariana Islands
google rank checker Norway
google rank checker Oman
google rank checker Pakistan
google rank checker Palau
google rank checker Palestinian Territory Occupied
google rank checker Panama
google rank checker Papua new Guinea
google rank checker Paraguay
google rank checker Peru
google rank checker Philippines
google rank checker Pitcairn Island
google rank checker Poland
google rank checker Portugal
google rank checker Puerto Rico
google rank checker Qatar
google rank checker Reunion
google rank checker Romania
google rank checker Russia
google rank checker Rwanda
google rank checker Saint Helena
google rank checker Saint Kitts And Nevis
google rank checker Saint Lucia
google rank checker Saint Pierre and Miquelon
google rank checker Saint Vincent And The Grenadines
google rank checker Samoa
google rank checker San Marino
Sao Tome and Principe
google rank checker Saudi Arabia
google rank checker Senegal
google rank checker Serbia
google rank checker Seychelles
google rank checker Sierra Leone
google rank checker Singapore
google rank checker Slovakia
google rank checker Slovenia
Smaller Territories of the UK
google rank checker Solomon Islands
google rank checker Somalia
google rank checker South Africa
google rank checker South Georgia
google rank checker South Sudan
google rank checker Spain
google rank checker Sri Lanka
google rank checker Sudan
google rank checker Suriname
google rank checker Svalbard And Jan Mayen Islands
google rank checker Swaziland
google rank checker Sweden
google rank checker Switzerland
google rank checker Syria
google rank checker Taiwan
google rank checker Tajikistan
google rank checker Tanzania
google rank checker Thailand
google rank checker Togo
google rank checker Tokelau
google rank checker Tonga
google rank checker Trinidad And Tobago
google rank checker Tunisia
google rank checker Turkey
google rank checker Turkmenistan
google rank checker Turks And Caicos Islands
google rank checker Tuvalu
google rank checker Uganda
google rank checker Ukraine
google rank checker United Arab Emirates
google rank checker United Kingdom
google rank checker United States
google rank checker United States Minor Outlying Islands
google rank checker Uruguay
google rank checker Uzbekistan
google rank checker Vanuatu
google rank checker Vatican City State (Holy See)
google rank checker Venezuela
google rank checker Vietnam
google rank checker Virgin Islands (British)
google rank checker Virgin Islands (US)
google rank checker Wallis And Futuna Islands
google rank checker Western Sahara
google rank checker Yemen
google rank checker Yugoslavia
google rank checker Zambia
google rank checker Zimbabwe


This is code you can add in your website:

$GOOGLE_API_KEY = 'Insert Your Google Custom Search API Key';
$GOOGLE_CSE_CX = 'Insert Your Search Engine ID';

//the search query
$query = urlencode($_POST["query"]);
//the domain for which to show the ranking
$domain = $_POST["domain"];

//gl - google host -
//hl - user language -
//pages - how many pages should the search extend

$pages = isset($_POST["pages"])?$_POST["pages"]:1;
$gl = isset($_POST["gl"])?$_POST["gl"]:"us";
$hl = isset($_POST["hl"])?$_POST["hl"]:"en";

$found = false;
echo "<ul>";
for ($page = 1;$page <= $pages && $found == false;$page++){
$apiurl = sprintf('',$query,$GOOGLE_CSE_CX,$GOOGLE_API_KEY,$hl,$gl,($page-1)*10+1);
$json = file_get_contents($apiurl);
$obj = json_decode($json);

foreach ($obj->items as $idx=>$item) {
if (strpos($item->link, $domain) ){
$found = true;
echo "<li>";
} else{
echo "<li class='other'>";
echo "<span class='rank'>".($idx + ($page-1)*10 +1)."</span>";
echo "<span class='title'>".$item->htmlTitle."</span>";
echo "<span class='link'>".$item->link."<small>▼</small></span>";
echo "<span class='snippet'>".$item->htmlSnippet."</span>";
echo "</li>";

if ($found !== true){
echo "<li>";
echo "<span class='title'>".$domain." not found</span>";
echo "</li>";
echo "</ul>";


2) Search Code PHP KEYWORD RANK CHECKER CODE listed here:


Check for keyword rankings PHP script is active , Position of the keyword checker Keyword planner PHP script and research tool. However, the PHP script I created to verify keywords displays a page's position or rating for a certain keyword search. Additionally, it displays a view of how a certain page appears on a web index results page. Although the term "keyword" refers to all results returned by an online search tool, I will focus specifically on keywords. This PHP script's keyword positioning checker allows you to see where a page ranks in Google for a certain search term. However, since keyword constraints exclude material from their pages, this poses some challenges.

Here is keyword ranking php script which you can find in search engine and also you can easily check your keyword position by using this php script

  * License: free for private and commercial use
    This code is free to use and modify as long as this comment stays untouched on top and one exception.
    URL of original source:
    Author of original source:
    This tool should be completely legal but in any case you may not sue or seek compensation from the original Author for any damages or legal issues the use may cause.
    By using this source code you agree NOT to increase the request rates beyond the IP management function limitations, this would only harm our common cause.
   Public redistributing modifications of this source code project is not allowed without written agreement. Contact me by email if you are unsure.
   Using this work for private and commercial projects is allowed, redistributing it is not allowed.
   The reason behind this is that my website shall stay the primary location for this source.
    If you need customization of this source code you are welcome to contact me
   Some possible extensions:
   * database integration with in/out queue for synchronous/asynchronous full automated script interaction
    * increasing available functionality, adding different search modes, different resultset parsing
    * modification into a scheduled script with custom data retrieval/placement
    * modification into a background service
 // ************************* Configuration variables *************************
 // Your seo-proxies api credentials
 $pwd="2b24aff3c1266-----your-api-key---";            // Your API password
 $uid=YOUR_USER_ID;                                   // Your API userid
 // General configuration

	// The URL, or a sub-string of it, of the indexed website. you can use a domain/hostname as well but including http:// is recommended to avoid false positives (like !
 $test_keywords="some keyword,another keyword";	// comma separated keywords to test the rank for
 $test_max_pages=3;														 	// The number of result pages to test until giving up per keyword. Each page contains up to 100 results or 10 results when using Google Instant
 $test_100_resultpage=0;													// Warning: Google ranking results will become inaccurate! Set to 1 to receive 100 instead of 10 results and reduce the amount of proxies required. Mainly useful for scraping relevant websites.
 //$test_safe_search="medium";										// {right now not supported by the script}. Google safe search configuration. Possible choices: off, medium (default), high  
 /* Local result configuration. Enter 'help' to receive a list of possible choices. use global and en for the default worldwide results in english 
  * You need to define a country as well as the language. Visit the Google domain of the specific country to see the available languages.
 * Only a correct combination of country and language will return the correct search engine result pages. */
 $test_country="global";													// Country code. "global" is default. Use "help" to receive a list of available codes. [com,us,uk,fr,de,...]
 $test_language="en";													 	// Language code. "EN" is default Use "help" to receive a list. Visit the local Google domain to find available langauges of that domain. [en,fr,de,...]
 $filter=1; 																			// 0 for no filter (recommended for maximizing content), 1 for normal filter (recommended for accuracy)
 $force_cache=0;																	// set this to 1 if you wish to force the loading of cache files, even if the files are older than 24 hours. Set to -1 if you wish to force a new scrape.
 $load_all_ranks=1;															/* set this to 0 if you wish to stop scraping once the $test_website_url has been found in the search engine results,
 																							 * if set to 1 all $test_max_pages will be downloaded. This might be useful for more detailed ranking analysis.*/
 $portal="int"; // int or us (must match your settings, int is default)
 $show_html=0;																	 	// 1 means: output formated with HTML tags. 0 means output for console (recommended script usage)
 $show_all_ranks=1;															// set to 1 to display a complete list of all ranks per keyword, set to 0 to only display the ranks for the specified website
 // ***************************************************************************
  * This is a working and full featured Google Rank Checker
 * Tis script can and should be use as a base for own developments and customizations but it is also useful as standalone tool
 * Knowing your website rank for important keywords and watching how it changes related to website changes or competition is essential, this tool can be a great help on that.
  * There are websites that might do the same for you but they are unreliable and often produce wrong results, this tool puts that power into your own hands.
  * Traffic estimation: 450kb per 100 results
 *  + API support - getting reliable results from Google can be a pain and most proxies are not well suited for this, seo-proxies makes it easy
  *  + local country result feature (default is the main english google result set) (read more in last notes)
  *  + multipage DOM parsing - this tool is an advanced project, it can test for more than one result page and will interpret the results like a real browser (DOM)
  *  + correct proxy management - built in IP management, the tool will use and manage IPs in an optimal way to avoid blocks, wrong results and similar issues
  *  + multi-keyword support - test for more than one keyword
  *  + local write rights to create the working directory and store files in it (script will create directory and files automated)
  *  + Remove timeout for console scripts (when run on console)
  *  + Based on usage consider increasing max memory for console scripts (when run on console)
  *Possible upgrades and ideas:
  *  + Multi-threading support can easily be added. delay_time() and the proxy API need adaption (&offset=n) for custom seo-proxies licenses with parallel proxy support.
 *  + Database support for ranking results is recommended for professional usage, this would easily allow a ranking history.
 *  + When used in production environments, emailing support should be added so any warnings or aborts result in an emergency email to the project manager
  *Last notes: 
 * DONATE if you like the source or information so I can keep working and updating.
  * The recommended source of IPs is the built in service. It is of course possible to modify the source code and change the proxy support.
  * But this can result in accuracy/gray+blocklist troubles and even legal issues with Google, it is not recommended to change the proxy source or the IP management functions without advanced scraping experience.
 * From time to time Google changes parts of the design, sometimes this can cause parsing issues. The website will try to always stay up to date on such changes.
  * In general it is not recommended to use 100 results per page, this will reduce the amount of proxies required (in best case by 10) but also reduce the 
  * accuracy of the ranking results. It is required to use the '10 results per page' option if ranking results shall be accurate.
 * The country specific results have been verified using geolocated IP addresses and browsers for UK, USA, DE and AT.
  * In this project I'm using the small "php keyword rank checker api which is used for google rank checker " to get this api please use this code.
 * In my tests it has been found that the Rank checker is able to produce IDENTICAL ranking results when using my license.
  * So it is possible to test for local results WITHOUT maintaining expensive proxies or servers in each of the countries.
  * However, I can't guarantee this for all results. But this was true for resultset I've personally tested.
  * The cache files contain a serialized php array. The main reason for this is that Google changes their layout from time to time, storing the raw html content
 * in cache files would require to keep all "old" processing methods to be able to parse the output at a later time.
  * The cache can be cleared by a crontab/scheduler which removes files older than 24 hours (based on unix "find" for example)
 96require "functions.php";
 99$PROXY=array();														// after the rotate api call this variable contains these elements: [address](proxy host),[port](proxy port),[external_ip](the external IP),[ready](0/1)
$LICENSE=array();													// contains details about the license used for proper IP management

if ($show_html) $NL="<br>\n"; else $NL="\n";
if ($show_html) $HR="<hr>\n"; else $HR="---------------------------------------------------------------------------------------------------\n";
if ($show_html) $B="<b>"; else $B="!";
if ($show_html) $B_="</b>"; else $B_="!";

 * Start of main()
if ($show_html)
	echo "<html><body>";

if (!count($keywords)) die ("Error: no keywords defined.$NL");
if (!rmkdir($working_dir)) die("Failed to create/open $working_dir$NL");

if (!$country_data) die("Invalid country/language code specified.$NL");

if (!$ready) die("The specified license ($uid) is not active. $NL");
if ($LICENSE['protocol'] != "http") die("The proxy protocol of license $uid is not set to HTTP, please change the protocol to HTTP. $NL");

echo "$NL$B Google rank checker for $test_website_url initated $B_ $NL$NL";

* This loop iterates through all keyword combinations
$rotate_ip=0; // variable that triggers an IP rotation (normally only during keyword changes)
$max_errors_total=3; // abort script if there are 3 keywords that can not be scraped (something is going wrong and needs to be checked)


foreach($keywords as $keyword)
	$max_errors_page=5; // abort script if there are 5 errors in a row, that should not happen
if ($test_max_pages <= 0) break;
$rotate_ip=1; // IP rotation for each new keyword
 	* This loop iterates through all result pages for the given keyword
	for ($page=0;$page<$test_max_pages;$page++)
		$serp_data=load_cache($search_string,$page,$country_data,$force_cache); // load results from local cache if available for today
		if (!$serp_data) 
			$ip_ready=check_ip_usage(); // test if ip has not been used within the critical time
			while (!$ip_ready || $rotate_ip)
				$ok=rotate_proxy(); // start/rotate to the IP that has not been started for the longest time, also tests if proxy connection is working
				if ($ok != 1)
					die ("Fatal error: proxy rotation failed:$NL $ok$NL");
				$ip_ready=check_ip_usage(); // test if ip has not been used within the critical time
				if (!$ip_ready) die("ERROR: No fresh IPs left, try again later. $NL");
					$rotate_ip=0; // ip rotated
					break; // continue
			delay_time(); // stop scraping based on the license size to spread scrapes best possible and avoid detection
			global $scrape_result; // contains metainformation from the scrape_serp_google() function
			$raw_data=scrape_serp_google($search_string,$page,$country_data); // scrape html from search engine
			if ($scrape_result != "SCRAPE_SUCCESS")
				if ($max_errors_page--)
					echo "There was an error scraping (Code: $scrape_result), trying again .. $NL";
				} else
					if ($max_errors_total--)
						echo "Too many errors scraping keyword $search_string (at page $page). Skipping remaining pages of keyword $search_string .. $NL";
					} else
						die ("ERROR: Max keyword errors reached, something is going wrong. $NL");
			mark_ip_usage(); // store IP usage, this is very important to avoid detection and gray/blacklistings
			global $process_result; // contains metainformation from the process_raw() function
			$serp_data=process_raw($raw_data,$page); // process the html and put results into $serp_data

			if (($process_result == "PROCESS_SUCCESS_MORE") || ($process_result == "PROCESS_SUCCESS_LAST"))
				if ($process_result != "PROCESS_SUCCESS_LAST")
				store_cache($serp_data,$search_string,$page,$country_data); // store results into local cache	
			if ($process_result != "PROCESS_SUCCESS_MORE")
				break; // last page
		if (!$load_all_ranks)
				for ($n=0;$n < $result_count;$n++)
				if (strstr($results[$n]['url'],$test_website_url))
					verbose("Located $test_website_url within search results.$NL");
		} // scrape clause
		for ($ref=0;$ref<$result_count;$ref++)
			//$rank_data[$keyword][$rank]['desc']=$serp_data['desc'']; // not really required
			if (strstr($rank_data[$keyword][$rank]['url'],$test_website_url))
	} // page loop
} // keyword loop

if ($show_all_ranks)
	foreach ($rank_data as $keyword => $ranks)
		echo "$NL$NL$B"."Ranking information for keyword \"$keyword\" $B_$NL";
		echo "$B"."Rank - Website -  Title$B_$NL";
		foreach ($ranks as $rank)
			if (strstr($rank['url'],$test_website_url))
				echo "$B$pos - $rank[url] - $rank[title] $B_$NL";
				echo "$pos - $rank[url] - $rank[title] $NL";

foreach ($keywords as $keyword)	
	if (!isset($siterank_data[$keyword])) echo "$NL$B"."The specified site was not found in the search results for keyword \"$keyword\". $B_$NL";
		echo "$NL$NL$B"."Ranking information for keyword \"$keyword\" and website \"$test_website_url\" [<



Free python keyword rank checker scripts available:

Are you poor and have no money to buy Enterprise Rank Tracker? Well, today is your lucky day. With this Python script, shell script and crontab, you can automate your Google Rank check in a few easy steps. I will walk you through how to implement this and run it daily. Note that the script currently does not use a proxy to check keyword rankings. So if you want to do a bunch of keywords, Google will recognize and show you captchas.

To update:
Updated the script with the ability to select the device to use for rank checking. The two options are mobile and desktop. Keep the old script here, but rename it to

Update 2:
It contains a keyword.xls file that runs all keywords from there. You no longer need to add each one to your .sh file. I also added a random sleep mode between queries to avoid being found by Google. Scripts are now simpler and easier to use.

table of contents

ongoing test
Create a shell script
cron jobs
Posts and Questions
Installing Python RoboBrowser


Install pip robobrowser
Once all dependencies are installed, we can start testing whether the script works as expected.

ongoing test
Before running the test, go to the keywords.xls file and add the keywords you want to check for rank. You can add as many as you like, but the more keywords you have, the more likely Google will block you. (Include option to use proxy out of the box.)

Then open a terminal, navigate to the folder where is stored, and give the script execute permissions.

chmod +x
Now you can call the script with two arguments after it.
The website you're looking for and the device you want to check is mobile or desktop.

python3 [site] [device]
for example
I want to check the site On mobile you need to put the keywords against the keyword nothing package and run the keywords.xls file.

python3 Mobile
This will return the keyword, the ranking of the keyword, the URLs ranking for on Google, the selected device, and the date this ranking check was run.

Make sure your device is in lower case. If you misspell the device or add a capital letter, the script will run on your mobile device


we are web development company , we have our own web media house as well as we have having profeesinals seo which have on page and off page services as above mentioned data you can able to understand we have given keyword ranking checker script in php , python now we are 


Free Backlink Checker Php Code :


function check_back_link($remote_url, $your_link)

{ $match_pattern = preg_quote(rtrim($your_link, "/"), "/");

$found = false;

if($handle = @fopen($remote_url, "r")){


$part = fread($handle, 1024);

if(preg_match("/<a(.*)href=[\"']".$match_pattern."(\/?)[\"'](.*)>(.*)<\/a>/", $part))

{ $found = true;

break; } } fclose($handle); }

return $found; }



here example which is use funtion 


if (check_back_link('YOURURL','YOURURL-2'))

{ echo 'link found'; } else { echo 'link NOT found'; };

// this prints 'link NOT found', unfortunately...













Let's Get Connected

It's time to put an end to your woes! Consult with industry veterans from Pvsys Group. Get in touch with our highly experienced team of professionals to discuss your next project.