add php code in css code example Example: adding css to php file echo "<link rel='stylesheet' type='text/css' href='CSS/main.css'>";