Four years after he established a beachhead with his Golden Globe for The Office, Ricky Gervais's invasion of America finally seems to be gathering some momentum, with his first Hollywood starring role: the lead in, of all things, a romantic comedy. As if that isn't surprising enough, he comes out of it pretty well.
Gervais plays Bertram Pincus, a successful but misanthropic New York dentist who likes his job because 90 per cent of the people he meets have their mouths shoved full of cotton wool. In hospital for a routine procedure, he dies briefly under anaesthetic; and when he returns, he finds that he can see ghosts: dozens, hundreds of ghosts, thronging the Manhattan streets and – once they realise he can see them – pestering him for attention.
Dead people, it turns out, are just as pushy and annoying as living people: even more annoying, because Bertram is their only means of contact with the material world, their only hope of straightening out whatever business it is that keeps them hanging around, and he can't shove cotton wool in their mouths. The unquiet souls include Frank Herlihy (Greg Kinnear), a slimy businessman who used to live in the apartment underneath Pincus: he wants Bertram to break up his widow's impending marriage to a supposedly gold-digging lawyer; and, having met the widow, Gwen (Téa Leoni), Pincus is only too happy to take the job on. All that stands in the way is the fact that she already has him tabbed as a miserable, self-absorbed, self-loathing bastard. So he embarks on a journey to rediscover his humanity, blah blah blah.
What keeps it from being nauseating is, first, a script (by David Koepp and John Kamps) that turns out to be far more solid than most of the characters. The film's whole eschatology, the picture it presents of the afterlife, is pleasingly consistent and has some original touches: Bertram's complete inability to distinguish the dead from the living, unless somebody walks through them; and, when anybody does walk through a ghost, they sneeze.
More significant is Bertram's realisation of what keeps the dead here: not that they haven't finished with us, but that we haven't finished with them; a discovery that gives the often flippant script a dimension of seriousness.
Meanwhile, the shades of other films hover. The jealous ghost watching as his beloved falls in love with another man is a steal from Steven Spielberg's Always, itself a remake of A Guy Named Joe. The whole storyline – misanthrope jerked into a love of life by supernatural intervention – can be traced back through Groundhog Day to A Christmas Carol. Any sense that it's simply derivative is undercut by a hint of self-consciousness: trying to con Bertram into helping him, Frank says that he's Gwen's guardian angel and pays a sidelong tribute to It's a Wonderful Life: "What, you won't help me earn my wings?"
The scenario is embellished with a generous spattering of gags. Bertram's sociopathic tendencies supply the occasion for most of these: "You don't like crowds?" Gwen asks Bertram. "It's not so much the crowds," he explains, "as the individuals in the crowds."
The second thing that stops you hurling is the acting – particularly that of Gervais, sliding insults out with admirable understatement and anti-timing, his effectiveness heightened by contrast with Kinnear's much sharper, more overtly comic approach. The supporting cast are also good: Kristen Wiig is particularly engaging as the surgeon presiding over Bertram's operation, less interested in her patient than in the question of how dark she should go with the spray-tan. When he finds out, somewhat belatedly, about his flirtation with death, she attempts to mollify him with the reassurance that the anaesthetist doesn't work there any more: "You'll be happy to know that St Victor's operates a very strict three-strikes policy." And Aasif Mandvi is quietly excellent as Bertram's submissive colleague, finally provoked into offering him some spiritual council: "One day, you're going to have to confront the ultimate question: this being a prick – what is it getting you?"
Not everything works. While it's nice to see a romantic comedy leading man who doesn't fit the Hollywood mould, Gervais isn't entirely plausible – it's not so much the shortness or the round face that Bertram admits to, as the scary make-up job (is that hair dyed? Are those his real eyebrows? Who told him eye-liner suited him?). The film may work better on the small screen. And, while Gervais undercuts the occasional sentimental note, there are one or two points where he needs to be able to sound convincingly romantic, and I'm not at all sure he manages it.
There are some absurdities in the plotting, too (not least the idea that Americans would employ an English dentist; have you heard the cruel things they say about our teeth?), and at times you can feel the gags being shoehorned in: at one point, Gwen turns out to own a large, foul-smelling dog, which allows for some decent slapstick but raises the question of where this behemoth has been hidden the rest of the film. While the dog is tethered outside a bar, Bertram, irritated at Frank's continual ghostly presence during what should be a tête-à-tête, persuades Gwen to list all her late husband's faults: it's a funny scene, but hard to see why Gwen doesn't smell a rat, why she buys Bertram's idea that this is useful therapy.
And this ties into the principal problem, which is a lack of emotional coherence. Bertram's romance with Gwen proceeds with inexplicable haste, given his lack of obvious physical or social graces: she seems far too ready to be won over by his sense of humour, to overlook his overpowering weirdness (including the talking to invisible people from time to time), to forgive him for what looks like manipulativeness coupled with possible mental-health issues. His climactic realisation that selfishness has got him nowhere, that he must seek salvation by helping ghosts, seems unnecessarily abrupt, a device rather than a development.
But, with those caveats, it is a warm, clever and often very funny film. On this showing, Gervais's assault on Hollywood looks winnable.