The San Francisco 49ers lost their first preseason game 23-3 to the Baltimore Ravens at M&T Bank Stadium in Baltimore, Maryland.