Lefteris Pitarakis, Associated Press
Author J.K. Rowling holds a copy of "The Tales of Beedle the Bard." The book was auctioned to raise funds for charity.

LONDON — A book of fairy tales created, handwritten and illustrated by J.K. Rowling sold for nearly $4 million at auction Thursday.

The buyer, Web retailer Amazon.com Inc., now owns one of only seven copies of "The Tales of Beedle the Bard," which is leather bound with silver mounts.

Amazon, in its unaccustomed position as a buyer rather than seller of books, was represented by London art agent Hazlitt, Gooden and Fox.

The book originally had been expected to sell for about $100,000. The standing-room-only crowd at Sotheby's auction house applauded as bidding topped the $2 million mark.

The money will benefit the Children's Voice, a charity co-founded in 2005 by Rowling and Baroness Nicholson, a member of Britain's House of Lords.

Rowling, 42, watched the auction on the Web from her home in Edinburgh, Scotland, and said she was ecstatic.

"This will mean so much to children in desperate need of help," she said in a statement. "It means Christmas has come early to me."

Amazon.com posted a handful of photos of the book's contents and said it will review the tales on its Web site. The company also launched a discussion board to answer questions about the book's contents from fans of Rowling's "Harry Potter" series.

Craig Berman, an Amazon spokesman, said the company plans a tour for the book of libraries and schools.

Rowling, whose "Harry Potter" books have sold nearly 400 million copies and been translated into 64 languages, wrote the Beedle tales after finishing the seventh and final work in the Potter series.

"'The Tales of Beedle the Bard' is really a distillation of the themes found in the Harry Potter books, and writing it has been the most wonderful way to say goodbye to a world I have loved and lived in for 17 years," Rowling said.

She said the six other copies of the "Beedle" books have been given to people who were closely connected to the "Harry Potter" collection.

The Children's Voice campaigns for children's rights across Europe, especially in Eastern Europe, where many children and teenagers grow up in institutions, often in what many activists regard as unacceptable conditions.

Rowling said the proceeds of the auction will "help institutionalized children who are in desperate need of a voice."

Sotheby's also auctioned "Marrakech," a painting by Sir Winston Churchill that he gave to President Harry Truman in 1951 and had remained in the Truman family. The work, which shows a panorama of the Atlas Mountains in Marrakech, Morocco, sold for $955,645.

Truman's daughter, Margaret Truman Daniel, had hand-carried the painting from 10 Downing St. to the United States on behalf of her father.

Churchill, who painted as a pastime and gave away many of his works, was Britain's prime minister from 1940-45 and 1951-55.