What Oli says, BUT BC337-40 (NPN) and BC327-40 (PNP) through hole TO92 transistors will meet 95% of your small transistor needs, and they have the direct equivalents of BC817 / BC807. The SMD versions are available in Asia as Leshan Radio parts (NPN & PNP through hole and SMD) with similar part numbers - LRC817, LRC807. These are genuine Motorola mask parts made by a joint venture company between Motorola and LR. They have a range of older lower tech Motorola parts plus their own parts as well. Some of their own parts are very useful.
LR transistors page 1/3
For larger wattages, higher voltage or current, low noise high FT etc search Digikey [As trav1s suggests] for "transistor" follow the yellow brick road (menu selections) to the relevant selector guide and enter required parameters. Digikey transistors end of yellow brick road is here . Then sort by price and choose the cheapest in stock at the required volume - or use this as a guide to buy elsewhere. Consider using only ROHS compliant parts.
If a part is too special to succumb to these methods, ask us here with a specific design question.
Taiwanese CETSEMI also make some extremely nice transistors and small MOSFETs. The CETSemi CES2310 will do most things that an amateur would expect a SOT23 N Channel MOSFET to do.