Science ships allow you to explore the universe. They are the only ship which can move through an unexplored jump, so you will need them to expand your empire. Because you start out the game able to see only your Home World, you should build at least one science ship the first turn of the game. An important maxim to remember is that "knowledge is power" so you should always have enough science ships to explore as much of the map as possible.
There are several competing views on how many science ships to build on the first turn. The number built usually depends on personal style. Some people argue that it is vital to see as much of the map as possible as fast as you can, and so build several science ships. These players often build as many science ships as they have unexplored jumps, and then build combinations of attack and colony ships until they get their empire established. Others take a more conservative approach, building only 1-2 explorers the firt round in order to keep tech development high. This works well if you have only 1 or 2 jumps from your home world, but in my opinion leaves dangerous gaps in your intelligence-gathering if you have 3 or 4.
An even more aggressive opening is to build one science ship for each jump, plus one or two colony ships. This is in effect an early overbuild, but since you won't be building anything else for a while you can usually get away with it. When you look at your tech development after making this build you might be tempted to change your mind, but most of the time the lack of further building does bring you back even with the other players.
Exploration through Force
Another point of view is that BR is the most important factor. If you wait for BR-2 to begin building and exploring, then you will be able to destroy enemy science and colony ships that you meet, while your ship remains undamaged and can continue exploring. These players build only a few, or even no, ships at the beginning and simply wait for BR-2. This is especially the case in Tech games, where you can build 1 BR-1 science ship (and nothing else) the first turn and be BR-2 the next turn.
My personal preference is to explore as fast as possible. In my opinion waiting for BR-2 is a dangerous strategy in both large games and small games. Accepting that "knowledge is power," I explore everything quickly. Then even if the enemy has waited for BR-2 I can see his ships coming and can react to counter them. Even if I sacrifice 4 BR-1 ships to do so, if I stop that BR-2 scout I have effectively blinded the enemy and cost him several wasted turns. For small games the wait is just too long and you have allowed your opponent to take the lead in exploration, for large maps BR is irrevolent because you will likely dismantle your scout in order to do a pop-trick before even meeting your opponent.
The importance of science ships is not diminished as the game goes on, as you still have to find the enemy's planets and Home World. An attacking fleet should always carry at least 1-2 science ships with it unless you know the fleet will be destroyed before it can reach an unexplored jump. There is little worse than nuking a planet at the font and not being able to explore the jumps leading off of it.
Even when attacking, be sure not to overlook the science ship's special abilities. If you have a fleet with science ships set to nuke a planet that has an unexplored jump it is often beneficial to set the science ship to explore rather than nuke. Your opponent has to assume you are going to nuke with it, so if his resources are stretched thin he might not be able to stop the exploration. In this case you might be able to explore further, or even get a free nuke the newly explored planet.
Don't be afraid, even late in the game, to build your science ships at BR-1. If you are exploring the advance toward an enemy's builder or Home World you should expect to lose any single science ship you send through unexplored links, so don't bother wasting an expensive ship to do the same work a cheap one will do. The only exception to this would be if you can't guarantee the ship's safety until it reaches the jump needing exploration. (There is also a special trick for using science ships with stargates that works nicely in these cases.)