How can I animate the Restrict Visibility property of an object?
Restrict Rendering

The feature you need to animate is the Restrict Render icon: , not the Restrict Visibility icon: . Restrict Visibility only effects whether the object can be seen in the 3D Viewport -- it does not effect rendering at all.



How To Render &amp; View Your Animation


Before you render your animation, first you should specify where you want the rendered animation to be saved and also the file name. To do this:  


Go to: Outliner window -> Render tab -> Output section -> specify the directory and file name  
Select your rendered file output format. Here, I'm selecting the video format MPEG. However, it's considered very bad practice to render straight to a video file -- I'm doing it here only for the sake of brevity.


  
Next, scroll down to the Encoding section and select an appropriate encoding format. Here, I'm selecting the MPEG4 format

 
Now go up and click on the Render Animation button:  

 
Now on your computer, go to the place where you saved your file and view it with a video file player:  

   


If you want to play your rendered animation directly in Blender, you can use:
Info -> Render -> Play Rendered Animation (CTRLF11)  

NOTE: The "Play" buttons shown under the Render Result window will NOT play your rendered animation -- they are only for previewing your animation before rendering it: 



You can read more about the different features of the Outliner window here and more about the Rendering Process here in the Blender Manual.