Few writers have bridged the gap between grownups and kids as seamlessly as Roald Dahl. Many of his best-known books (Charlie and the Chocolate Factory, Matilda, James and the Giant Peach) swirl with childlike fantasy tempered by dark humor and even darker moments of peril.

Movies based on Dahl's books have been a mixed bag, but Steven Spielberg's The BFG — Dahl's epic story of a little girl kidnapped by a Big Friendly Giant — may be the best of the lot. It's a visual spectacle of wonder and whimsy, crowned by a warmhearted performance from Oscar winner Mark Rylance (Bridge of Spies) in the title role.

Young Sophie (bright-eyed Ruby Barnhill) is, like so many young literary heroines, an orphan, living under the strict shadow of a hopelessly distracted caretaker. Unable to sleep one night, Sophie spots a giant gamboling through the streets of 1980s London — and he spies her, as well. Afraid she will tell the world about him, the giant plucks Sophie from her bed, tucks her away in his bindle and whisks her to the land of giants — vaulting forests, leaping oceans, and skipping up and down mountains en route. This heart-stopping sequence, much of it seen from Sophie's tumbled and disoriented viewpoint, sets the stage for the wonders to come as Spielberg ushers us from this world to quite another one.

Sophie soon becomes friends with the giant, but there's a hitch: The BFG has forgotten that his fellow giants like to eat children, forcing him to devote energy and imagination to protecting her from their prodigious appetites.

Walt Disney Co./Courtesy Everett Collection

Mark Rylance and Ruby Barnhill in "The BFG"

As their adventures intensify, so does the bond between tot and titan. Through layers of computer-generated effects that render him a gangly tower of a man with enormous ears and a gooselike neck, Rylance wins Sophie's heart — and ours — with a gentle smile and a lyrical voice that brings to life some of Dahl's most inventive dialogue. For giants, you see, have their own special language — a twisty-turny torrent of phraseology that sounds like English but is something entirely its own. Screenwriter Melissa Mathison has wisely infused the script with as much of Dahl's original giant language as possible; thus, we get the BFG referring to Sophie as a "titchy little sanderwhipper," while the art of conversation is dubbed "babblement." The BFG's favorite pastime (flaunting his flatulence) is cheerfully designated "whizzpopping."

For as long as the film stays in Giant Land, The BFG remains enthralling. Only when Sophie and her outsize friend return to London does the narrative lose its way a bit. The pair arrive on a mission to alert Queen Elizabeth (Downton Abbey's Penelope Wilton) that big and decidedly nonfriendly giants are roaming the world at night, gobbling up children. This narrative detour was in fact part of Dahl's original, but it worked better on the page thanks to Quentin Blake's fanciful pen-and-ink illustrations. Fully rendered through CGI technology, the big-screen version of the giant's calamitous tea with the queen achieves a sort of photorealism that's disturbing, rather than whimsical.

Amid all the dangerous delights on display here, however, that complaint is small potatoes — or "snozzcumbers," as the BFG would say. Like the very best films, The BFG takes you someplace you've never been, somewhere you never dreamed existed. And unlike so many children's films that seek to appease attendant grownups with the occasional double entendre or awkward pop reference, The BFG has a defiantly ageless outlook. With apologies to Dr. Seuss, you might say The BFG reassures viewers young and old that "A person's a person, no matter how tall."