Films based on real events are a risky business. Sometimes the task of adaptation can be accomplished with a degree of delicacy that rings true—Jeff Nichols’ “Loving” is a fine recent example. If done with a heavy hand, however, a movie can seem phony even if every incident in it has a basis in fact. That, unfortunately, is the case with “Hidden Figures,” which, like “Loving,” involves an important turning point in American racial history that occurred in segregation-era Virginia, but is played so broadly that it comes across as essentially false. In that respect it resembles “The Help,” the 2011 drama that offered a scrubbed-down version of reality that was more comforting than enlightening.

The screenplay, by director Theodore Melfi and co-writer Allison Schroeder, is based on the book by Margot Lee Shetterly about the shattering of the color barrier among the workers at NASA in the early 1960s. The time predated the advent of IBM machines to check the mathematical calculations prepared by male engineers to allow for space travel, and so the work was done by female personnel who were known as “computers.” They included a battery of black women, among them three friends who are the focus here: Katherine Goble (Taraji P. Henson), shown in a prologue as a gifted math prodigy; Dorothy Vaughan (Olivia Spencer), who has been doing the work of group supervisor though she’s not been granted the title (or salary); and Mary Jackson (Janelle Monae), the most overtly rebellious of the trio.

The narrative concentrates on how each of them shows exceptional talent that ultimately creates a crack in the accepted barriers to advancement by women in general, but black women in particular. Vaughan, recognizing the threat to the livelihood of all the “computers” that comes with the arrival of the first IBM mainframe, surreptitiously masters the operation of the machine, making herself indispensable in its use (and able to help her compatriots). Jackson, assigned to the staff designing the prototype of the Mercury space capsule, is encouraged by her boss (Olek Krupa) to apply to a program to train engineers, and so successfully challenges the segregationist exclusion of blacks from the college classes that are prerequisites for it.

While their efforts bring them up against obtuse white bosses who cannot recognize their talents, such as personnel director Vivian Mitchell (Kirsten Dunst), the emphasis is nevertheless on Katherine, who is transferred to the Space Task Group headed by Al Harrison (Kevin Costner), which has come under increasing pressure to succeed as Soviet triumphs in the field accumulate and American efforts remain stymied. There she encounters the same sort of resistance as Dorothy and Mary, not only from the team’s secretary (Kimberly Quinn) but from chief engineer Paul Stafford (Jim Parsons), who’s obviously envious of her computational skill and her innovative approaches to problems. Despite being overwhelmed by the demands on him Harrison, on the other hand, is fairly quick to recognize her extraordinary ability and to take advantage of it. Another who will do so is astronaut John Glenn, portrayed with fresh-faced exuberance by Glen Powell, who in the end prefers her calculations to those spat out by the IBM.

The individual workplace triumphs of each of the three women are portrayed with a degree of manipulation that practically compels the audience to cheer them on; subtlety is a rare commodity here, not only in face-offs against hidebound opponents like Mitchell and Stafford, but even more in a sequence involving Katherine’s need to run across the entire complex to reach the sole restroom assigned to blacks, and Harrison’s summary way of dealing with such an obviously absurd situation, or another in which Dorothy is accosted for daring to enter a forbidden area of a public library. (An encounter the three women have with a state trooper early on is played pretty much for laughs.) Less ham-fisted is the scene in which Mary makes her argument before a judge who’s relatively sympathetic for the time and place.

The heroines have to face doubts even outside the NASA compound. Mary’s husband (Aldis Hodge) cautions her about striving for impossible dreams, and Johnson (Mahershala Ali), a smooth military officer, makes the mistake of underestimating Katherine’s steely determination at their first meeting. Both men, however, come to recognize how exceptional the women are, just as their white bosses do.

“Hidden Figures”—an overly cute title, but Shetterly must bear responsibility for that—tells a genuinely compelling story, but does so in a fashion that too often feels artificial, even borderline sitcomish. The synthetic quality extends to the period details of the physical production, which, as designed overall by Wynn Thomas with costumes by Renee Ehrlich Kalfus, looks way too slickly spic-and-span. (There is, however, a nice visual joke in the identical outfits—white shirts with black trousers, ties and shoes—worn by all the engineers in Harrison’s unit.) The almost impeccable character of the settings is accentuated by Mandy Walker’s bright, glistening cinematography.

And yet it’s hard to resist the charm of the three lead actresses, who milk even the sappiest moments for all they’re worth. Costner brings his patented brand of straightforward sincerity to Harrison, though Ali is completely untaxed by a bland role, while Parsons, Dunst and Quinn are unable to give much shading to their bluntly-written characters.

Though its celebration of these remarkable women is certainly apt, “Hidden Figures” unfortunately goes overboard trying to become an unabashed crowd-pleaser.