The few times I get questioned on why my children aren't in school, the first question usually is "Can you do that?", meaning is it actually legal to homeschool. Depending on the circumstances, I sometimes flippantly answer that "There's no law telling me I can't!"
The reality is that it depends on where you live. The legalities of homeschooling vary from place to place, and who's making the rules. In most of the world, it's legal to homeschool. There are a few countries where it's absolutely forbidden -- usually rooted in socialist ideals of government (Germany and Sweden are examples where the laws forbidding homeschooling have caused some tragic results).
Generally speaking, to legally homeschool will mean that you will notify your local school and/or school board of your intent to homeschool, and then at the end of the year, submit some kind of proof of homeschooling. I happen to live in a jurisdiction where neither is necessary; I neither have to notify my local school board (since my children have never been in school or are registered with the school board), nor do i have to provide anything at the end of the year. But most places, at least in North America, do require notification and some kind of end-of-year proof.
Notification can be as simple as a form to fill out and send in. Sometimes it is a little more detailed, and requires you send in a copy of your plan for the year, listing such details as subjects or topics to be studied, books to be used, goals to be achieved. The level of detail will depend on your local laws.
End of year proofs are just as varied. It could be as simple as sending in an attendance sheet, showing days and hours of school work logged, or perhaps a standardized achievement test result. It could be a little more complicated, involving keeping a portfolio of work completed, test results and attendance, or even having your program (and possibly your children) evaluated by an approved state evaluator.
During the year, you may have to keep your end-of-year requirements in mind. If you need to submit an attendance log, you'll need a way to keep track of attendance. It might be as simple as marking off days on a wall calendar, or maybe you'll use a program such as HomeschoolTracker or HomeschoolPlanet. If you are required to keep a portfolio, you'll need to create a system to file away work completed, whether that's a box to hold the lapbooks you completed or photographs of the to-scale model of the solar system, or simply a stack of completed workbooks. If you need an end-of-year test, commonly used models include the Iowa Test of Basic Skills or the Brigance Diagnostic Screening tests, or your jurisdiction may require their own standardized test.
For more information on local laws and requirements: