A nine-year-old Scottish girl who attracted two million readers to a blog documenting her school lunches, consisting of unappealing and unhealthy dishes served up to pupils, has been forced to end the project after the council banned her from taking pictures of the food in school.

Martha Payne, from Argyll, started the blog at the end of April, initially as a writing project with her father. With the permission of teachers she photographed lunches as they arrived on their white plastic trays and gave the contents – generally meagre, often fried – marks out of 10 on a "Food-o-meter" scale for how healthy they were and whether or not she found any stray hairs.

In little over a week the blog, NeverSeconds, was being posted on social networking sites and had received 100,000 visitors. Martha got a tweet of congratulation from the chef-turned-campaigner Jamie Oliver.

Soon afterwards, pupils at the school were informed they could have as much salad and fruit as they wanted with their lunch. Martha began encouraging readers to donate to a charity, Mary's Meals, assisting with school food in east Africa, and they contributed £2,000. The worldwide readership meant she was sent photos from schools around the world, which she published alongside her own. It was apparent that overseas pupils were being offered far healthier dishes.

Martha blogged anonymously under the name Veg, and as publicity for the blog picked up she was featured and named in a series of newspapers, as well as other food blogs. That, it seems, was the final straw for the local council, Argyll and Bute, which runs her primary school.

On Thursday, came a post from Martha from titled simply "Goodbye": "This morning in maths I got taken out of class by my headteacher and taken to her office. I was told that I could not take any more photos of my school dinners because of a headline in a newspaper today.

"I only write my blog not newspapers and I am sad I am no longer allowed to take photos. I will miss sharing and rating my school dinners and I'll miss seeing the dinners you send me too. I don't think I will be able to finish raising enough money for a kitchen for Mary's Meals either."

Martha's father, Dave, added a note of explanation, saying: "Martha's school have been brilliant and supportive from the beginning and I'd like to thank them all. I contacted Argyll and Bute council when Martha told me what happened at school today and they told me it was their decision to ban Martha's photography."

As the reader count on the blog ticked up at a faster speed than ever, the council faced a predictable storm of protest on Twitter and other social networking sites. The council had no immediate response to the decision, although last month it said its school meals were "fully compliant with nationally agreed nutritional standards".