Your home is your castle?
The government, or anyone else, certainly can't enter without your invitation or without legal authority. One way entry without your consent can be legally authorised is a warrant issued by a court of law. There are very specific provisions in Act of Parliament setting out when a warrant for entry can be issued.
Entry not in accordance with the terms of the warrant is illegal.
Yesterday, Prime Minister David Cameron went into a person's home with immigration officers. The Guardian has reported on legal doubts about whether he was entitled to do so.