This documentation relates to CiviCRM version 3.1. It's not maintained anymore.
Current version of documentation.

Import Large

Skip to end of metadata
Go to start of metadata

This page refers to outdated version of CiviCRM. Check current version of documentation.

Documentation Search

CiviCRM 3.1 Documentation

Support and Participation

Developer Resources

CiviCRM book!

Make sure to check out Understanding CiviCRM as well! You can also support this project by ordering a hard copy.

Importing LARGE quantities of data.

If you have trouble importing large data files, try the following.

  1. This setting relates to the file size limitation (how big a file you can import) — change the CIVICRM_MAX_IMPORT_FILESIZE value in sites/default/civicrm.settings.php to something like 8388600.
  2. There is also some overhead in PHP to consider and PHP will only wait for a specified time before timing out. Setting the max_execution_time will help extend the time period that PHP will wait before timing out.

The appendix below indicates the php.ini settings and where/how they can be overridden. Some can be overridden in the .htaccess file or some settings can be set in other ways (php.ini, httpd.conf or .htaccess, etc.). Most shared hosts do not allow individuals to make changes to php.ini or httpd.conf files.

That being said however, the php execution limit can be overridden in the .htaccess file which is located at the root of your CiviCRM site. I modified mine to the following and it worked and thus, my large imports worked. I hope this is useful.

Add the max_execution_time setting to the .htaccess file at the site root — a complete example is below. 360 is in seconds so, in this case, PHP would wait for 6 minutes before timing out. Up it as you feel it's needed for your case.

php_value magic_quotes_gpc 0
php_value max_execution_time 360
php_value register_globals 0
php_value session.auto_start 0

PHP_INI_USER 1 Entry can be set in user scripts or in Windows registry
PHP_INI_PERDIR 2 Entry can be set in php.ini, .htaccess or httpd.conf
PHP_INI_SYSTEM 4 Entry can be set in php.ini or httpd.conf
PHP_INI_ALL 7 Entry can be set anywhere

Also see .

  • None

Creative Commons License
Except where otherwise noted, content on this site is licensed under a Creative Commons Attribution-Share Alike 3.0 United States Licence.