How to replace a chain pulley for garage door?
Loosen the tensioning screw the BIG SHINY BOLT - lower left side of the rail guide in the image you posted. BEFORE YOU LOOSEN it ... 
KEEP YOUR CHAIN IN POSITION. Put a nail through the slots from one end across the chain rail guide and tape it with duct tape or tie it - you could use a wire tie as well if you have one it is much easier.

There should be either a plate that your tensioning pulley is attached to via the bolt in the center of it - you should be able to unscrew it - keep in mind that it might be a left hand bolt AKA: LEFTY TIGHTY, RIGHTY LOOSEY - which is opposite of Standard Bolts which are called Right Hand - Righty Tighty, Lefty Loosey. 

So to test for Left Hand Bolt try turning 1/8 turn to the right and see if it loosens. Or check the service manual. 

MAKE SURE THE GARAGE OPENER IS UNPLUGGED!

Loosening the jacking screw will allow you to remove the chain from the pulley. At this point you should be able to remove the entire pulley with jacking screw ;which might make it easier for you to see how the pulley is assembled in order to remove it, or you can unscrew the pulley. See an edited picture of your picture.