Call WordPress functions from custom PHP code In order to execute WordPress functions from any PHP code you need to load the wp-load.php file, like this: require_once("/path/to/wordpress/wp-load.php"); … tags: & category: -