Web Hosting Info


featured partner

The IP to Country Database


Last updated by jinesh on Fri, 01/05/2007 - 18:10
Download the latest IP-to-Country Database (Last updated on December 14 2010)

For more information on the database format and how to use it read the User's Guide.
    Comment viewing options:
    Select your preferred way to display the comments and click 'Save settings' to submit your changes.
    How often is the ip-to-country.csv.zip file updated
    Posted by jalanis on Tue, 05/11/2004 - 15:47.

    hello, do you know how often is the ip-to-country.csv file updated???
    it's quite important jejeje thanks.

    Approximately one time per mo
    Posted by absolut on Wed, 09/08/2004 - 11:57.
    Approximately one time per month
    Where does one download the .csc.zip file?
    Posted by rxy122 on Tue, 01/18/2005 - 00:20.
    Does anyone have the link to download the ip-to-country.csv.zip file?
    Link for Zip
    Posted by carlpr on Fri, 01/21/2005 - 00:44.
    link at top of page!
    Lol :)
    Posted by rebel29270 on Thu, 05/05/2005 - 13:55.
    lol :)
    Posted by rebel29270 on Thu, 05/05/2005 - 10:29.
    Hello I want to knwo if there is somewhere where we can subscribe to know when a new db update is aviable.

    Posted by rebel29270 on Thu, 05/05/2005 - 10:39.

    I want to know if there is a news letter where you can subscribe ro know when there is new update on the ip list


    Libya still Unknown Country !
    Posted by Mowaffak on Wed, 06/15/2005 - 07:57.
    Please can add new IP addresses for Libya to ip-to-country.csv:
    from to and decimal:
    from 1055924224 to 1055932415
    PHP/MySQL import scripts
    Posted by willem_spruijt on Thu, 08/18/2005 - 11:25.
    He Guys,
    Here's a good-working script for importing your csv-file into your database.

    Mysql vs db-files
    Posted by dupex on Sun, 09/04/2005 - 22:24.
    What is fastest?

    A mysql lookup,

    or locally stored files like php.net have?

    How to use include/ip-to-country.inc
    Posted by method on Fri, 03/31/2006 - 18:39.
    hi dupex could u tell me how i can use

    i be happy if u show me how i can use it with php.thanks
    Posted by sivalee on Wed, 01/25/2006 - 09:04.
    Hi There,

    do any one knws why down loaded csv file contain ip range with out first two zero's example.

    "33996344","33996351","GB","GBR","UNITED KINGDOM"
    "50331648","69956103","US","USA","UNITED STATES"

    But in the exmaple page (http://ip-to-country.webhosting.info/node/view/54) in the site it shows as

    "0033996344","0033996351","GB","GBR","UNITED KINGDOM"
    "0050331648","0083886079","US","USA","UNITED STATES"

    Could you please tell me what is the correct format of above 2

    South Africa is missing?
    Posted by online chess on Fri, 02/03/2006 - 17:35.
    It appears South African IPs are mostly missing from the database. And it has been the case for quite some time now. Here's a few IPs that resolve to "some place we don't know", but should be assigned to "ZA":

    online chess
    Parser3 operator for importing data in MySQL database
    Posted by redactor on Thu, 06/01/2006 - 14:29.
    ### Parser3 (http://www.parser.ru/en/)
    ### operator for importing IP-to-Country
    ### data into mysql
    ### (c) Redactor 2006
    ^if(!def $filename){



    $incoming_csv[^table::load[nameless;temp/ip-to-country.csv;$.encloser["] $.separator[,]]]
    ^connect[mysql://root@localhost/iptoc] {
    ^void:sql{TRUNCATE mirr_iptoc}

    Ip to city database
    Posted by kunwarbs on Wed, 08/23/2006 - 17:08.
    is there any database available to convert ip into CITY rather than country?
    A php script to convert csv to sql
    Posted by npelov on Tue, 08/29/2006 - 02:38.
    I wrote a little script to convert the csv file to sql import script: #!/bin/php
    foreach($lines as $line){
    echo "error";
    echo 'insert into ip2c values("'.($matches[1]).'","'.($matches[2]).'","'.($matches[3]).'","'.($matches[4]).'","'.($matches[5]).'");'."\n";

    copy this script and .csv file in the same dir then run:
    convert.php >ip2c.sql

    Here is create table syntax:

    CREATE TABLE `ip2c` (
    `start` int(10) unsigned NOT NULL default '0',
    `end` int(10) unsigned NOT NULL default '0',
    `a2` char(2) NOT NULL default '',
    `a3` char(3) NOT NULL default '',
    `country` varchar(100) NOT NULL default '',
    PRIMARY KEY (`start`,`end`)
    Cpanel blocking
    Posted by s_patd on Thu, 11/30/2006 - 20:48.
    Is there a way (maybe a plugin or something) to block all the people from one specific country from accesing your site from CPANEL? Or any other way, except from php or other onpage scripting. I mean blocking direct from the server?

    panic at the disco