WASHINGTON—The Supreme Court on Thursday agreed to decide whether the government can reject trademarks that some people find offensive, accepting a free-speech case that could determine the fate of a legal battle involving the Washington Redskins football team.

The justices, in a brief written order, said they would consider whether the Asian-American rock band The Slants can register a trademark on its name. The group’s frontman, Simon Tam, sought the trademark but was denied by the U.S. Patent and Trademark Office, which...