Highest birth rate in Europe + highest divorce rate + highest percentage of women working outside the home = the best country in the world in which to live. There has to be something wrong with this equation. Put those three factors together - loads of children, broken homes, absent mothers - and what you have, surely, is a recipe for misery and social chaos. But no. Iceland, the block of sub-Arctic lava to which these statistics apply, tops the latest table of the United Nations Development Programme's (UNDP) Human Development Index rankings, meaning that as a society and as an economy - in terms of wealth, health and education - they are champions of the world. To which one might respond: Yes, but - what with the dark winters and the far from tropical summers - are Icelanders happy? Actually, in so far as one can reliably measure such things, they are. According to a seemingly serious academic study reported in the Guardian in 2006, Icelanders are the happiest people on earth. (The study was lent some credibility by the finding that the Russians were the most unhappy.)

Oddny Sturludottir, a 31-year-old mother of two, told me she had a good friend who was 25 and had three children by a man who had just left her. 'But she has no sense of crisis at all,' Oddny said. 'She's preparing to get on with her life and her career in a perfectly optimistic frame of mind.' The answer to why the friend perceives no crisis in what any woman in a similar predicament anywhere else in the western world might consider a full-blown catastrophe goes a long way towards explaining why Iceland's 313,000 inhabitants are such a sane, cheerful, successful lot.

There are plenty of other, more obvious factors. Statistics abound. It is the country with the sixth highest GDP per capita in the world; where people buy the most books; where life expectancy for men is the highest in the world, and not far behind for women; it's the only country in Nato with no armed forces (they were banned 700 years ago); the highest ratio of mobile telephones to population; the fastest-expanding banking system in the world; rocketing export business; crystal-pure air; hot water delivered to all Icelandic households straight from the earth's volcanic bowels; and so on and so forth.

But none of this happiness would be possible without the hardy self-confidence that defines individual Icelanders, which in turn derives from a society that is culturally geared - as its overwhelming priority - to bring up happy, healthy children, by however many fathers and mothers. A lot of it comes from their Viking ancestors, whose males were rampant looters and rapists, but had the moral consistency at least not to be jealous of the dalliances of their wives - tough women who kept their families fed in the semi-tundra harshness of this north Atlantic island while their husbands forayed, for years at a time, far and wide. As a grandmother I met on my first visit to Iceland, two years ago, explained it: 'The Vikings went abroad and the women ran the show, and they had children with their slaves, and when the Vikings returned they accepted it, in the spirit of the more the merrier.'

Oddny - a slim, attractive pianist who speaks fluent German, translates English books into Icelandic and works as a city councillor in the capital, Reykjavik - offers a contemporary case in point. Five years ago, when she was studying in Stuttgart, she became pregnant by a German man. During her pregnancy she broke up with the German and reconnected with an old love, a prolific Icelandic writer and painter called Hallgrimur Helgason. The two returned to Iceland where they lived together with the new baby and in due course had a child of their own. Hallgrimur is devoted to both children but Oddny considers it important for her first-born to retain a close link to her biological father. This happens on a regular basis. The German flies over and stays at Oddny and Hallgrimur's far-from-spacious home for a week, sometimes two, at a time.

'Patchwork families are a tradition here,' explained Oddny, who was off work, at home, on the Thursday morning we met, looking after her youngest child. 'It is common for women to have kids with more than one man. But all are family together.'

I found this time and again with people I met in Iceland. Oddny's case was not atypical. When a child's birthday comes around, not only do the various sets of parents turn up for the party, the various sets of grandparents - and whole longboats of uncles and aunts - come too. Iceland, lodged in the middle of the North Atlantic with Greenland as its nearest neighbour, was too far from the remit of any but the more zealously obstinate of the medieval Christian missionaries. It is a largely pagan country, as the natives like to see it, unburdened by the taboos that generate so much distress elsewhere. That means they are practical people. Which, in turn, means lots of divorces.

'That is not something to be proud of,' said Oddny, with a brisk smile, 'but the fact is that Icelanders don't stay in lousy relationships. They just leave.' And the reason they can do so is that society, starting with the parents and grandparents, does not stigmatise them for making that choice. Icelanders are the least hung-up people in the world. Thus the incentive, for example, 'to stay together for the sake of the kids' does not exist. The kids will be just fine, because the family will rally round them and, likely as not, the parents will continue to have a civilised relationship, based on the usually automatic understanding that custody for the children will be shared.

Reykjavic, Iceland, May 2008: City Councillor Oddny Sturludottir tells us why Iceland is the best place in the World. Photograph: Ari Magg

The comfort of knowing that, come what may, the future for the children is safe also helps explain why Icelandic women, modern as they are (Iceland elected the world's first female president, Vigdis Finnbogadottir, a single mother, 28 years ago), persist in the ancient habit of bearing children very young. 'Not unwanted teen pregnancies, you understand,' said Oddny, 'but women of 21, 22 who willingly have children, very often while they are still at university.' At a British university a pregnant student would be an oddity; in Iceland, even at the business-oriented Reykjavik University, it is not only common to see pregnant girls in the student cafeteria, you see them breast-feeding, too. 'You extend your studies by a year, so what?' said Oddny. 'No way do you think when you have a kid at 22, "Oh my God, my life is over!" Definitely not! It is considered stupid here to wait till 38 to have a child. We think it's healthy to have lots of kids. All babies are welcome.'

All the more so because if you are in a job the state gives you nine months on fully paid child leave, to be split among the mother and the father as they so please. 'This means that employers know a man they hire is just as likely as a woman to take time off to look after a baby,' explained Svafa Grönfeldt, currently rector of Reykjavik University, previously a very high-powered executive. 'Paternity leave is the thing that made the difference for women's equality in this country.'

Svafa has embraced the opportunity with both arms. For her first child, she took most of the parental leave. For her second, her husband did. 'I had a job in which I was travelling 300 days a year,' she said. She had her misgivings, but these were alleviated partly by the knowledge that her husband was at home, partly because of the top-class state education that Iceland provides, starting with all-day pre-schools, rendering private schools practically nonexistent. ('I think there is one, but 99 per cent of kids, be their parents plumbers or billionaires, use the state system,' Svafa said.)

The 300 days' travelling job was as deputy CEO in charge of mergers and acquisitions for a generic pharmaceutical company called Actavis, where Svafa worked for six years. During this period the company rose from global minnowhood to become the third largest of its kind in the world, buying up 23 foreign companies along the way. A propagandist not just for her former firm, which she left when she could no longer fight the guilt she felt over her maternal absences, she listed some of the more notable feats of entrepreneurial prowess her country had achieved in the past 10 years, boom-time in what had traditionally been a fish-based economy. Icelandic banks now operate in 20 countries, and the Reykjavik-based company deCODE is a world leader in biotechnological genome research. Icelandic firms are gobbling up food and telecommunications firms in Britain, Scandinavia and Eastern Europe, further evidence of the island's economic growth.

Svafa is a lively, wiry woman with a sassy haircut and a sharp, humorous mind. And she has a corner office to match. Spacious, minimalist (so much so she does not even have a desk) and modern in the clean Nordic style, it has the feel of a lounge and views to kill for. From one window you see over Reykjavik's red and green rooftops to the fishing port and the dark blue sea; from another you look on to a ridge of low, snow-capped mountains. It's a beautiful landscape to look at but a hard one in which to live, especially in the 1,000 years Iceland was inhabited prior to the invention of electricity and the combustion engine. 'You have to be not only tough but inventive to survive here,' said Svafa. 'If you don't use your imagination, you're finished; if you stand still, you die.'

As the Vikings showed, part of that imagination means getting out into the world. That is what Svafa did (she studied for a PhD at the London School of Economics, lived in the US, spending a total of 10 years abroad) and what practically all Icelanders do. Very few do not speak excellent English. But now that Iceland has become prosperous the invitation is out to the world to come to Iceland. Reykjavik University has staff from 23 countries and the idea, after a planned move in two years to what Svafa describes as a new space-age campus, is to expand the foreign presence both in terms of teaching staff and students, and convert the university into a hub of global business education. Reykjavik University is already entirely bilingual. 'Students who only speak English can come and do postgraduate studies here.' Does nobody worry about losing the Icelandic language, when, after all, so few people speak it? 'Not at all,' declares Svafa. 'Our language is safe.' Not prey to the nationalist neuroses of other small countries (though practically none are smaller than Iceland), Iceland's obsession is with embracing the world, not fearing it. 'We are into brain gain, not brain drain. We want to do what the Americans have done to great effect, in our specific case to create an elite campus in Europe that attracts the best in the world.'

Icelanders know how to identify the best and incorporate it into their society. I talked about this to the Icelandic prime minister, Geir Haarde, whom I met at an official event at a steamy public swimming bath, a popular meeting place for Icelanders, like pubs for the British. Easygoing as everybody else I met, and without anything dimly resembling a bodyguard anywhere near him (there is almost no crime in Iceland), he agreed on the spot to sit down and do a quick interview.

'I believe we have blended the best of Europe and the United States here, the Nordic welfare system with the American entrepreneurial spirit,' he said, pointing out that Iceland, unlike the other Nordic countries, had exceptionally low personal and corporate tax rates. 'This has meant not only that Icelandic companies stay and foreign ones come, but that we have increased by 20 per cent our tax revenue owing to increased turnover.' Which is not to say that Iceland has been immune to the financial panic affecting the rest of the world right now. Icelandic banks being, in the US manner, aggressive and optimistic global players, there are worries they may have over-extended themselves. The rise in food and oil prices is generating the same sort of headlines in Iceland's papers as we are seeing elsewhere. Yet there is no suggestion that the economic system itself is under threat. Icelanders will continue to receive not just free, top-class education but free, top-class healthcare, private medicine being limited in Iceland chiefly to luxury procedures, such as cosmetic surgery.

Dagur Eggertsson, until recently the mayor of Reykjavik and every inch a future prime minister of Iceland, made the point to me that what has happened in Iceland has defied economic logic. 'In the Eighties and Nineties right wingers in the US and UK were saying that the Scandinavian system was unworkable, that high state investment in public services would kill business,' said Dagur, a boyish, super-bright 35-year-old who, like most Icelanders, is a furiously hard-working multi-tasker - as well as a politician, he is a doctor. 'Yet here we are, in 2008,' he continues, 'and you look at the hard economic statistics and you see that these last 12 years we and the Scandinavian countries have been roaring ahead. Someone called it bumblebee economics: scientifically, aerodynamically, you cannot figure out how it flies, but it does, and very nicely, too.'

Iceland's spectacular success comes from that capacity for hard work Dagur exemplifies, plus that imperative for creativity Svafa spoke of, plus an American faith in the feasibility of big ideas. 'Many of us have lived in the US, studied there,' said Geir Haarde, 'and what we have both taken from them and found that naturally we share is that can-do attitude - that if you work hard, anything can be done.' Svafa seemed to be the living expression of what Haarde was describing. She rejoiced in the civilised generosity of the Icelandic state but worked in pursuit of her own private goals with tireless optimism.

A similar spirit lies behind the success of Reykjavik Energy, the company that provides Icelanders with most of their hot water and electricity. Pipes dug deep into the earth's icy crust extract not oil, but water, which one kilometre down reaches temperatures of 200C. In 1940, 85 per cent of Iceland's energy came from coal and oil. Today, 85 per cent comes from underground volcanic water, which supplies half the country's electricity needs at a price just two-thirds of the European average. Iceland has the world's largest geothermal heating system, and the world is coming to have a look. The prime ministers of China and India have visited Iceland in recent years to see what they can learn about clean, cheap renewable energy and Reykjavik Energy is engaged in joint projects to replicate the Icelandic model in places as far flung as Djibouti, El Salvador, Indonesia and China.

The success of Reykjavik Energy is a metaphor for Iceland's broader achievement: harnessing the harshness of nature and transforming it, through invention and hard toil, into rich, fruitful energy. Artists have done much the same. The country is crawling with writers, painters, film makers and - like Oddny - accomplished musicians. Iceland has Björk, its cool answer to Madonna, but also a national symphony orchestra that plays to the highest standards all over the world; it has its own opera company (while I was there, La Traviata was being performed at the Reykjavik Opera House, entirely by Icelanders).

Baltasar Kormakur, a former TV soap opera heart-throb, is a successful local film director whose films have been shown in 80 countries, and is about to make his first Hollywood film this year. He has also directed a play at the Barbican, where he will soon be staging a production of Shakespeare's Othello. As for writers, half the population appears to have written a book, as if inspired by the single greatest cultural legacy Iceland has so far given the world - the 13th-century Viking sagas, which Jorge Luis Borges, the greatest writer never to receive a Nobel prize, described as the first novels, 400 years ahead of Cervantes. As a consequence, the one thing Icelanders could do that many in richer countries could not, even in the 19th century, was read - and the abundance of bookshops in Reykjavik is testament to this. Painting as an art form did not exist in Iceland until 100 years ago, but a large sector of the population dabbles in it now and at least 100 Icelanders live off their art full time.

Haraldur Jonsson, who studied in Paris and whose father was a champion multi-tasker (he was both an architect and a dentist) is an abstract painter, sculptor and video and performance artist who describes his task as 'making the invisible world visible', transforming emotions into things you can see and touch. He has exhibited all over the world, including London, Barcelona, Berlin and Los Angeles. Why is there such an abundance of artists in Iceland? What drives them? 'We do it so as not to become mad,' replied Haraldur, who is tall, nervy and thin with eyes that have the concentrated energy of a laser beam. Not to become mad? 'Yes, to keep the beast at bay.' The beast? 'The beast is Iceland, this island on which we live with its terrifyingly harsh nature, its bitter ever-changing weather. It's Goya's dark nightmare world, beautiful but grotesque. This is the moody beast of Iceland. We cannot escape it. So we find ways to live with it, to tame it. I do it through my art,' said Haraldur, whose attempts to pacify the monster have also included the writing of three books in which 'there are no animals, no trees. We have to have a rich internal life to fill the empty spaces, to fill the silence with our own noise.'

There is another beast to which Iceland owes a debt: the Second World War. The Icelanders must be the only people in the world to whom Adolf Hitler bequeathed a legacy of value. Before the war, Iceland was Europe's poorest country. Suddenly, in 1939, it became a strategic location of immense value. The British and the Germans raced for it, and the British got there first. They established a military base on a finger of land near the Reykjavik coast. 'Suddenly there was an abundance of jobs that were, for the first time ever, unrelated to fishing or farming,' recalled Asvaldur Andresson. 'I remember that before the war we barely had roads, and those we had we had to build with picks and shovels. The British and Americans came and then it was Caterpillar trucks and tar roads and all sorts of wonderful new tools with which to work.'

Asvaldur, who was born in 1928 in a fishing town in Iceland's wild far east called Seydisfjordur, emigrated west to Reykjavik at the end of the war and found a job as a bus driver at the US base. After that, following long hours of hard night-time study, he spent most of his life as a refurbisher of bashed-up cars. His life was always tough, but especially when he was growing up, when Iceland was that worst of possible mixes, a Developing World country with brutally cold weather. He left school at 12 and went to work on a fishing boat amid the icy storms of the Arctic circle's southern edge. His sister died of whooping cough at the age of three, and when his father died, Asvaldur, then 16, was out at sea, so he did not find out about it until after the burial. He worked 16-hour days all his life to keep his family fed. Today, he has a full-time job looking after his invalid wife. The blessing is that he receives money from the state to do so, a big reason (consistent with the culture of family cohesion) why most old people in Iceland live not in residences but at home. 'I look back at my life and I see how this country has changed and I can hardly believe my eyes,' said Haraldur.

The most remarkable thing is what has become of three of his grand-daughters, all grown up now. One makes documentary films in Paris; one is a bio-technology whizz who assists surgeons in a Reykjavik hospital; the eldest, at 26, has a flying licence from the United States and is undergoing training to become a pilot with Ryanair. Icelandic women being the early reproducers that they are, Asvaldur and his wife have not one or two but five great-grandchildren.

They are all sure to be receiving a fine education, especially should any of them happen to go to a school I visited in Reykjavik called Hateigsskol. The principal, a quietly passionate man called Asgeir Beinteinsson, showed me around. The children range from the ages of six to 16, and every classroom, which we visited unannounced, was a picture of cheerful industry. Apart from the wide variety of subjects obligatory to all, from cookery to carpentry via all the traditional lessons, what was striking was the ingenuity in the teaching and the degree of liaison with the parents. One method of teaching for younger children involved the use of drama to explain history and science. The story of the first settlers who left Norway in 874, for example, is learnt by acting out how they would have navigated to Iceland using the sun and the stars, and how they survived when they first arrived on Iceland's barren rocks. As for the parents, there is one member of staff whose job it is to compile detailed data on internal assessment exercises conducted with a view to keeping the school on its toes, and standards high. After consultation with pupils, teachers and parents, progress is rated on everything from the quality of maths teaching for nine-year-olds to the satisfaction levels of the teachers with their colleagues to the pupils' feelings about the school buildings. The information is then made available to the parents on the internet.

'The philosophy behind everything we do,' said Asgeir, 'is that we must challenge the children with a broad educational foundation, teach them in a warm, creative environment where we respect everyone equally. All are equal.' Asgeir and his staff have, like many other Icelanders, looked abroad for ideas and inspiration. Two teachers I met had just returned from England, where they had spent time at a school in Birmingham with a reputation for doing an especially good job. Asgeir himself has been to Denmark, Scotland, the United States and Singapore, and he was off to New Orleans the week after I met him. For good measure, all teachers have the opportunity to take a year off to study a subject of their choice on full pay.

If the bumblebee flies, if Iceland is the world's best place in which to live, and one of the richest, it is because of the way governments have added enlightened policies to the island's pragmatic, inventive human raw material. 'I as a medical doctor and as a politician believe that there is an intimate link between the country's health and the quality of political decisions that are made,' said Dagur Eggertsson, Reykjavik's former mayor. 'We were the poorest of nations 100 years ago, but we all could read and we had strong women. On that we have now built strong policies. My point is that more important for the health of a country than not smoking and eating well are the social phenomena we stress here: equality, peace, democracy, clean water, education, renewable energy, women's rights.'

Dagur, like the many people I spoke to in Iceland who were proud of their country, was confident but not complacent; content but ambitious - and open to the world in all its diversity. That was manifest even at Asgeir's school, where I came across children from China, Vietnam, Colombia, even Equatorial Guinea.

When I was talking to Svafa about the better influences from the rest of the world that Iceland seemed to have wisely plucked, or just happened to have, we mentioned, as the prime minister had done, the humaneness of Scandinavia and the drive of the United States. We also discussed how the Icelanders - who have excellent restaurants these days and whose stamina for late night partying must come from the Viking DNA - seemed to have much of southern Europe's savoir vivre. Then I put it to her that there was an African quality to Iceland that the rest of Europe lacked. This was to be found in the 'patchwork' family structures Oddny had spoken of. The sense that, no matter whether the father lived in the same home or the mother was away working, the children belonged to, and were seen to belong by, the extended family, the village. Svafa liked that. 'Yes!' the pale-skinned power executive exclaimed, in delighted recognition. 'We are Africans, too!'

Partly by dint of travel, partly by accident, Iceland, we agreed, was a melting pot that had contrived to combine humanity's better qualities, offering a lesson for the rest of the world on how to live sensibly and cheerfully, free from cant and prejudice and taboo. Iceland could not be less like Africa on the surface; could not be further removed from the lowest country in the UNDP's Human Development Index, Sierra Leone. Yet the Icelanders have had the wisdom to take, or accidentally to replicate, the best of what's there, too. Without any hang-ups at all.