The final episode filmed in the series was The Last Farewell two-hour special (sometimes referred to as season ten) where the residents of Walnut Grove decide to blow up all the buildings in town, aside from the church and the schoolhouse so that the town’s new owner cannot benefit from all their years of work. But did they really blow up the buildings? Yes, they actually did.
Part of the agreement the show had with the owners of the property, Big Sky Ranch, where the series was filmed, was that they had to restore it to its former state without the buildings. It was still a working property and there were fears about animals getting injured in what would become abandoned buildings after filming ended, as well as safety and security reasons.
It was reportedly Michael Landon who came up with the idea to blow up the buildings, as they were still coming up with an idea for the final two-hour episode for NBC as well as on how to dismantle the town after filming. Hence the idea of blowing up the town was born.
And yes, the buildings were blown up during filming, it wasn’t CGI or special effects. They did do several run-throughs prior to blowing them up, to ensure none of the cast or crew could be injured when filming was happening.