Fuel filters typically connect with the fuel line in two places, the intake side and the outtake side, and the entire assembly is held in place with a mounting bracket. Your car's fuel filter can be located anywhere along the fuel line, meaning it could be at the back of the car near the gas tank, or under the hood closer to the engine.
After you've located the filter, you'll need to relieve the pressure in the fuel line; otherwise, fuel can spray everywhere, creating a safety hazard and a huge mess in the process. You can relieve the fuel pressure a number of different ways, but a common method involves removing the fuse for the fuel pump and running the engine until it dies.
The next step is to disconnect the negative terminal of your car's battery to minimize the chance of a spark igniting gas fumes. Next, examine the fuel filter to determine how the fuel line is attached. In some cases, clips hold the fuel line onto the filter. In other cases, "banjo bolts" or other specialized fasteners connect the fuel line to the filter. Make sure to pay special attention to any washers or O-rings on the connection assembly. While the replacement fuel filter will typically come with new connecting hardware, you'll need to know how everything fits together when you install the new filter.
Before disconnecting the fuel lines, wrap the filter in a towel to catch any fuel that spills out of the lines and filter. Once the fuel lines are disconnected, detach the filter from the mounting bracket and dispose of it.