The Power Reactant Supply and Distribution (PRSD) aka cryo tanks on the orbiter had relief valves that fed manifolds that vented overboard, H2 on the starboard side, O2 on the port, both over the wings. This shows the starboard side.
Here is a drawing showing the overboard relief from the Press Manual.
The other answer is talking about the "manifold relief valves" which allowed an isolated, overpressurized cryo manifold to relieve back into the tanks. It was not a tank or overboard pressure relief system.
The H2 tank relief valves cracked at 302 psig, the O2 at 1005 psig. Normal pressure was ~ 250 for H2, 850 for O2.
AFAIK this never happened in the history of the program. EGIL (the flight control position responsible for the electrical system) would have been in big trouble. The PRSD tanks were vacuum insulated (I know it sounds redundant, but the Orbiter did operate in the atmosphere) and normal usage kept the tanks below the crack pressures. In fact normal ops was turning heaters on to keep the pressure up.
See here https://space.stackexchange.com/a/39233/6944 for info on cryo tanks and normal operations
You could also vent reactants through the fuel cells themselves - this was called "purging". The valves that did that were not pressure operated though, they were opened by the crew. This purging was done routinely, every flight.
Source: Diagram- Shuttle Operational Data Book Vol IV aka the Crash Book and personal notes.
Addendum showing what a normal pressure history in the tanks was like:
I've added a plot showing actual cryo tank pressure data from STS-88. The pressure in the 5 O2 cryo tanks is plotted, the graph covers about 30 minutes. At the beginning, one tank's heaters are in AUTO and the heaters are cycling to supply the fuel cell demand. When the crew turned the heaters off for a test, the pressure dropped and all 5 of the tanks supplied the demand. When the crew put the heaters back in AUTO, the one tank picked up all the demand.