Firstly, always read product labels and follow all label instructions. If you are ever unsure on anything, please confirm with your supplier before applying your fertiliser.
Regarding granular and liquid fertiliser, always store them out of reach of your pet(s). Granular fertiliser can easily be mistaken for pet food, and liquids can be mistaken for water. Keep your pet(s) indoors while you fertilise your lawn. Read on for advice on how long to keep your pet(s) off your lawn (it depends on the type).
Granular fertiliser is safe to use as long as the granules are watered correctly into the lawn/earth. Once this is done, they are very difficult for your pet(s) to access. But it’s always best to keep pets off your lawn for 24 hours after application.
The main issue with granular fertiliser regards chickens. Chickens can source granules lower in the turf profile than other animals. Either do not spread granular fertiliser where chickens roam or ensure the granules have dissolved before letting your chickens return. This usually takes a few days.
Most fertilisers however are not that harmful to most pets; here is a good link you can check out http://www.pethealthnetwork.com/dog-health/dog-toxins-poisons/fertilizer-and-mulch-dangers-dogs
Regarding liquid fertilisers, once they are dried on the leaf then you are fine to let your pet(s) onto your lawn. This usually takes a few hours depending on the weather.
If your pet is a known grass eater, it is best to keep them off your lawn for 48 hours, or as long as possible. Again, if you are using a liquid fertiliser and your pet does eat grass, please check with the manufacturer for what exactly is in the product. You should always request a safety datasheet for that product.
Of course, if you believe your pet(s) may have inhaled, ingested or come into contact with fertiliser (signs can include burnt paw pads, red and watering eyes, vomiting and lethargy) seek veterinary advice immediately.
Follow the above advice and you can provide a safe playground for your pet(s).