James says religion is worthless if someone does not bridle his tongue (James 1:26). He defines "pure and undefiled religion" as visiting orphans and widows in their affliction and keeping oneself unstained from the world (James 1:27).
James 1:26–27 tests claimed devotion by pointing to three concrete indicators. First, someone can think they are devout yet undermine that claim by unrestrained speech; self-deception makes their worship-practice empty. Second, James names what “clean” and “unspoiled” devotion looks like before God: active care for vulnerable people who are suffering. These verses conclude the opening movement that urges readers to be doers of the message, not merely hearers (James 1:22). James has warned about desire giving birth to destructive outcomes (James 1:14–15) and has emphasized receiving the implanted word with humility and then acting on it.
James treats “religion” (religion) as something that can be claimed (“thinks…”) yet proven empty. The passage ties genuine devotion to observable marks, not to self-assessment alone.
A careful answer keeps the immediate passage, the book's argument, and the whole-Bible storyline together, so the question is answered in context instead of as a detached idea.
Start with James 1:26, then read the surrounding section so the answer stays connected to the passage's flow.
26If anyone among you thinks himself to be religious, while he doesn`t bridle his tongue, but deceives his heart, this man`s religion is worthless.