By the time Malorie Blackman read a work of fiction featuring black characters, she was 23. The book was Alice Walker's The Colour Purple, set in the American south in the 1930s, and its impact on her was huge. Blackman was then working as a computer programmer, having given up her childhood dream of becoming an English teacher after the careers adviser at her London grammar school put her off. But she still read children's books, and in her spare time began to write her own, and imagine they might one day be published.

It took a long time. None of the texts for picture books she offered publishers was accepted, and she changed tack before an editor at the Women's Press said yes to a collection of short stories for teenagers that blended horror and science fiction. Published after she left her job watching stock prices in the City because she "couldn't care less whether the prices went up, down or sideways", it was called Not So Stupid!

This week Blackman, now 51, was named the eighth children's laureate, a position she inherits from mega-selling Gruffalo author Julia Donaldson and will hold for two years. At the announcement of her appointment in London on Tuesday, a few days before publication of her latest novel for teenagers, Noble Conflict, she looked delighted. "I think younger children have been incredibly well served by the laureates we've had, but maybe teenagers haven't had as much of a look-in, so I'm looking forward to redressing the balance," she said.

Blackman is also the first black laureate and a forceful advocate for black and ethnic minority children's needs and rights. In making up her mind to write about black people in 1980s London, she grabbed a baton previously held by African-American pioneers including Alice Walker and Maya Angelou, who in the 1970s and 80s did so much to popularise writing about black people's lives.

In her 20s she was a volunteer reader in a south London primary school – when her exhaustion following a museum trip made her think perhaps she didn't have the stamina for teaching after all – but her awareness of the lack of black faces in books didn't go away. "I remember going into a bookshop and the only book I saw with a black child on the cover was A Thief in the Village by James Berry and I thought, is this still the state of publishing? Then I thought either I can whinge about it or try to do something about it. So that was a major reason for me wanting to write books for children, because I wanted to write all the books I'd missed as a child."

But it was years before Blackman would address the subject of race directly. She says people criticised her for not doing it sooner, "but people love to stick you in boxes and put labels on you, and I didn't want that. I thought, I wanted to write the kind of books I would have loved to have read as a child." These were books with characters who looked more like her, but not books with race as their theme. Most importantly they were books that were hard to put down. Blackman is a devotee of the cliffhangers she enjoyed in her weekly comics, and makes an effort to end her chapters at a suspenseful point.

A teacher once ripped up a comic in front of her with the order "don't read that rubbish", after which the teenage Malorie learned to read them concealed inside a copy of the Guardian. "There is such snobbery about comics even now," she says, "and that is something I would like to tackle. It's about the story, not about the form."

Her first novel, Hacker, pitted a teenage girl against the bank that thinks her father is a thief. She followed it up with several novels combining technological themes with thriller-type plots in which enterprising children rescue their parents and avert disasters. Her writing was brisk and vivid, her focus on story more than style. But fearful once again of being pigeonholed, she thought "time to change, so then I wrote Pig-Heart Boy" – about a teenager who undergoes an experimental transplant, it was shortlisted for the Carnegie medal – "and some other books. I wanted to have a body of work behind me before I wrote about racism. But then with the Stephen Lawrence case I thought now I'm going to write about racism, but I'm going to do it my way."

She planned to write about slavery and its legacy, "but all my friends – black, white, Asian, whatever – were underwhelmed by that idea. My white friends were like, what do you want to write about that for? It's so long ago. And my black friends were like, what do you want to write about that for? It's so painful." So she thought again, and came up with the idea for a series of dystopian adventures in which roles and races would be reversed.

The alternative modern society in which the Noughts & Crosses books are set is governed by the black Crosses, who have all the power, status and money, while the miserable underclass of former slaves are the white Noughts, otherwise known as "Blankers". The first book's plot revolves around the Romeo and Juliet-style romance (albeit with the emphasis more on friendship than sex) between Nought Callum and Cross Sephy, whose father is a government minister.

During the story Callum is drawn into the Liberation Militia, a terrorist group seeking to overthrow the racist state with methods that include bombs and kidnapping. It is provocative stuff, and must have been more so when Blackman's publishers offered the foreign rights for sale in 2001. Predictably, as this coincided with 9/11 and the launch of the "war on terror", the Americans weren't interested, although a US edition has since appeared.

The novel was adapted for the stage by the Royal Shakespeare Company and spawned three sequels, the last two of which carry the story into the next generation and describe the struggles of Callum and Sephy's daughter, Callie Rose. A novella and short story were also spun off. The whole project was a great success of which Blackman is rightly proud, not least because she managed to make her troublesome subject matter the opposite of worthy. The books are pacy, entertaining and very popular.

By making her young white characters the victims of oppression but without dwelling on their race, she offered a new way in. And while she was angry when she sat down to begin Noughts & Crosses, having just watched a TV documentary about the Stephen Lawrence case, she knew she had to channel this. Her parents came to London from Barbados as part of the Windrush generation and never wanted to talk about their slave ancestors, so she understood from them and also from friends that it is not only white audiences who are resistant to tales of colonial barbarism.

"I think it was painful. Their thing was they had started a new life, so why hang on to that past," she says, "which I do regret because I'd love to know more about my background. I don't know which part of Africa my ancestors are from and that does give you a feeling of being fractured from your past."

But there was plenty of life experience that Blackman could pour into Noughts & Crosses, which she says was her most painful and satisfying book to write. Blackman, like Callum, was accused of stealing the ticket the first time she travelled in a first-class train compartment. Like the noughts in her book, she was frustrated by plasters that didn't match her skin. And like Callum, she had a habit of standing up to her teachers. "I remember being in a history lesson and saying to my teacher, 'How come you never talk about black scientists and inventors and pioneers?' And she looked at me and said, 'Because there aren't any.'"

The racism Blackman experienced as a child in south London is shocking. Her father drove a bus, her mother worked in a pyjama factory, and there were five kids. The family avoided public places such as restaurants, and Blackman remembers being called a "jungle bunny" and told to go back to where she came from. "It was a strange and confusing time," she says. "I would think, but I was born in Clapham. But as a child, you get on with it."

She was sent out of class the first time she went to school with her hair loose in an afro, and was told by the careers adviser at her girls' grammar school that "black people don't become teachers". She began a polytechnic course in business studies instead, but left before the end of the first term. Reapplying to university, she got into Goldsmith's College as she had always wanted, but found she enjoyed her job at a software company on a year out and never took up the place. She still takes regular courses, most recently drumming at the City Lit college in London where she took her first writing class, but Blackman never did get a degree.

Her education left her with many unanswered questions, some of which she answered for herself as a young adult when she spent much of her spare time and money in a specialist bookshop researching black history. It also shaped her conviction that efforts to engage ethnic minority children in education are essential if they are not to feel excluded.

Earlier this week we reported on Blackman's concerns about the government's widely trailed plans to reform the curriculum by making the focus more national, less multicultural. "It's a mistake to get very inward-looking and say, OK, if you're doing history we're going to concentrate on the royals or Winston Churchill," she says. "That's not to say they're not important, but I would rather have learned about how working-class people lived in Tudor times or whenever, but we never did that. I wanted to learn about something that felt more relevant." At school, Blackman says, she gave up history as soon as she could.

Unlike David Cameron, who argued two years ago that multiculturalism has failed, Blackman believes it needs to go further. "I don't think we've gone far enough with it in terms of making sure children know about different cultures and ways of living. If you want people to feel they are part of a society, it's about making it more inclusive."

She signed the recent petition to keep Jamaican-born nurse Mary Seacole on the national curriculum, and thinks any weakening of the current emphasis on diversity could have dire results. "I do feel it's very dangerous to make it seem that history is the province of a certain segment of society. History should belong to all of us and it needs to include people from different cultural backgrounds. Otherwise it risks becoming irrelevant to children who could then become disenchanted with education."

Strikingly, Blackman argues that this process of marginalisation begins before children get to school. When her own teenage daughter was young she would order picture books about black people from the US, so scarce were they in the UK, though she knew the African-American families they depicted were not the same as her British one (Blackman's husband, Neil, is white and Scottish). "We need more books that are specifically about the BME [black and minority ethnic] British experience, and that's why I bang the drum for getting more diverse books out there, and for getting rid of the idea that if a book contains pictures of a black or Asian child, it's going to have a limited market."

Through talent, application and a self-belief she says she learned from her mother, Blackman made it. Her backlist features more than 60 books for all age groups, several of which have won awards. Pig-Heart Boy was adapted for television, and Noughts & Crosses won a spot in the BBC's 2003 Big Read poll of all-time favourite books. Despite worries about raised levels of intolerance, about Ukip and Islamophobia, she still believes we are moving on as a society.

But her life story also taught her to distrust authority, and many of her novels are about the crises produced when those in charge get things wrong. In Noughts & Crosses we are invited to sympathise with terrorists. In her latest and even more dystopian novel, Noble Conflict, the reader is forced to switch sides. The world has been divided after environmental disaster and geo-engineering failure, and insurgents based in the arid Badlands are wreaking havoc on the peace-loving Alliance. The Guardians are the elite soldiers who lead the defence, but Blackman's fans won't be surprised when Kaspar, her hero, finds himself doubting all he has been taught.

Blackman's parents, she says, had an unquestioning attitude to those in charge of their children's education. When her teachers were racist her parents asked what she had done wrong, and she believes it is partly the mistakes of their generation that set in train the cycle of underachievement among children from Caribbean backgrounds that continues today. "So many of my friends didn't do what they wanted," she says. "One of them wanted to go to art college, and her headteacher told her a supermarket was looking for supervisors. A number of us were told similar things – this is your level and no higher – and I think disenchantment set in."

When Blackman was told she was not university material she remembers thinking, "I'll show you, you old cow! If anything, it made me work harder." But she knows not everyone had her confidence, and she speaks with sadness of "a whole generation, my generation, that was undervalued and lost". Newer migrants, she suggests, don't carry the weight of frustration and disappointment of their African-Caribbean peers.

Over the next two years Blackman will do what she can to raise expectations, visiting schools and promoting libraries. "As a child I loved Star Trek," she says. "You had Russians and Americans and a black officer and a Japanese officer, and I thought, yes that's the ideal, having all those people working together, when we get to the 21st century it's going to be brilliant because we're going to be past all this nonsense. And here we are in the 21st century and it's the same old, same old. Sometimes I feel we need to get over ourselves and move on. There are bigger issues."