Question seen at Facebook electronics discussion group:
Easier solution is to get a new transformer / power supply with 3V output. There are many universal adjustable switch mode power supplies that can be adjusted to 3V.
You you can use fixed output linear regulator like AMS1117 (3.3V) or LM7803 (3V) or LM317 (adjustable to 3V with two resistors) to drop the voltage to the needed levels, but those Will get hot if you try to get any considerable current from 3V output. At 1A current at 3V output voltage from 12V input voltage they will produce 9W of heat! You will need a large heat-sink.
Alternatively, you can use an adjustable step-down DC-DC converter (sold as modules). I would recommend external DC-DC converter/regulator module to the voltage to 3V. I have tested somewhat expensive feature rich modules like DC-DC Step Down Power Supply Adjustable Module With LCD Display With Housing Case and Winners® 5A DC Adjustable CNC Step Down Power Supply.
There are also cheap modules that have just trimmer adjustments, some cheap modules can work OK but some cheap Chinese ready made modules do not work as promised.
The final idea is to modify the mains power supply you have, but this is only a viable option for experts who understand the operation of power supplies and the potential dangers related to them well. With some switch mode mains power supplies it is possible to adjust output voltage at some range by modifying the voltage feedback circuit (usually change resistor or zener diode value). To get basic understanding of the power supply technology check out my Switched-mode power supply tutorials post.
To understand what you need to change or if any changes are possible you need to know the circuit operation (preferably full circuit diagram available with someone who understands it or someone with good reverse-engineering skills) so that you know what to change properly. Mistakes can cause cause power supply malfunction (not work at all, unstable voltage, wrong voltage) or kill someone (electrocution and fire dangers).
For example Bebek Electronic has sold (and seems to sell) switch mode mains power supply circuit boards that could be used to to build power supplies (needs to be fitted inside protective case etc.) and can be adjusted to different voltages by changing a resistor value on the circuit board. HAKKURIVIRTALÄHDE 7.Volt 800mA and HAKKURIVIRTALÄHDE 6.5V 800mA product pages have full circuit diagrams and modification instructions for several different output voltages.