Spain beat Team USA on Friday in the Olympic men's water polo match, 8-7.
That means Spain advances to the fifth-place game on Sunday, against either Hungary or Australia. The United States will play for seventh place.
That rank is a bit of a blow for the U.S. team, which is headed by captain and Stanford graduate Tony Azevedo, and which won silver in Beijing 2008.
Azevedo is joined by other players with Bay Area connection including Layne Beaubien, Peter Hudnut, John Mann and Peter Varellas.
The U.S. women's water polo team won gold on Thursday.
Lisa Fernandez contributed to this report.