The youth hostel network has a great number of hostels around the country (http://juventude.gov.pt/P...). There are also many camping places. 'Wild camping' camping outside camping parks is not allowed, unless you have the land owner's agreement. It is legal to sleep in a car such as a campervan also outside of camping places.
There's a wide and abundant hotel offering all through Portugal.
If budget is a concern, and you want a true 'typical-Portuguese' experience, gather your courage and try one Residencial, the home-like hostels ubiquitous in cities and most towns. In most places you can get a double room for €25-35 Oct 2006. Be sure, however, of the quality of the rooms.
On the luxury side, you might try the 'Pousadas de Portugal', a network of hotels managed by the Pestana Group remarkable for using very beautiful ancient buildings like Palaces and Castles and also for having excellent service, consistent all over the country. You will do well in eating out eventually, as the cuisine of Pousadas is frequently both expensive and boring, although it appears the trend is changing for the better mid-2008.
The "Casas de Campo" Turismo de Habitação, Turismo Rural, Agro-Turismo, when traveling through the countryside, are also an affordable, picturesque and comfortable B&Bs. Don't expect them to be open all year round, and try to contact them beforehand if your itinerary depends on them.