Want to make your text "speak" with natural and realistic voices that rival real people? Microsoft Edge browser's built-in "Read Aloud" feature can do just that! It supports dozens of languages and various tones, and the best part is that it's completely free.
Based on this functionality, the open-source project edge-tts
is also widely popular, and many free text-to-speech tools are developed based on it. However, with the increasing number of users, Microsoft has begun to rate limit the voice-over requests. Now, even with slightly higher usage, you'll encounter a 403 error, making it impossible to continue synthesizing speech.
How to Avoid or Reduce 403 Errors?
Since this is an API service provided by Microsoft, rather than an open-source project, local deployment is not feasible. In any case, speech synthesis must connect to Microsoft's servers.
Deploy to Cloudflare: This can reduce the frequency of 403 errors, but it cannot completely avoid them.
- If you're interested, you can refer to this tutorial: https://pyvideotrans.com/edgettscf
Use Dynamic IP Proxy: Automatically changing the IP every few minutes can effectively avoid 403 errors. Stability depends on the quality of the dynamic IP. If the reliability of the dynamic IP is 97%, then the availability of
edge-tts
can also reach 97%.- This seems to be the best solution currently. Of course, high-quality dynamic IP proxy services usually require payment. Free proxies are often of poor quality and cannot meet the needs.
So, how to configure a dynamic IP proxy, and which services are worth recommending?
Dynamic IPs cannot guarantee 100% availability; actual availability may only be between 85% and 95%.
Here, I'll use Proxy302, which I have personally used, as an example. It provides foreign residential IPs, switches approximately every 5 minutes, and is billed based on traffic (US$1.5/GB).
Below are the detailed steps for activation and usage:
I. Register an Account
Visit 302AI to register an account. This account and balance are shared with Proxy302. The reason for recommending registration from 302AI is that its minimum top-up amount is US$5, while Proxy302's minimum top-up amount is US$20. For the first attempt, it is recommended to top up a small amount first to reduce risk.
Open this link to register: https://gpt302.saaslink.net/teRK8Y Register an account using your email and complete email verification.
Top up your balance: Top up as shown in the figure below, with a minimum top-up of US$5.
II. Log in to Proxy302.com
After topping up, log in to https://dash.proxy302.com/login using the same account and password.
After logging in, you can see the balance.
III. Create a Dynamic IP Proxy Address
Click Dynamic IP (Short-Term) --> Pay-As-You-Go on the left navigation bar as shown in the figure above.
Then click General Proxy Generation --> Generate General Proxy in order, as shown below.
- After generation, you can see the newly generated proxy address in Existing Proxy --> Purchased Proxy below. Click the help button behind the address, set the country of the proxy IP, and copy the proxy address.
- As shown in the figure below, select
United States (US)
in the country, click to generate a randomSession
, and copy the address at the bottom.
Important Note: Each time you need to copy the proxy address, be sure to click the
help
button to copy it.
IV. Apply the Proxy Address to the Video Translation Software
You must first upgrade the video translation software to version v3.50.
In the same directory as the
sp.exe
file of thepyVideoTrans
video translation software (or in the directory wheresp.py
is located if it is a source code deployment), create a plain text file namededgetts.txt
.Paste the proxy address copied in the previous step into the
edgetts.txt
file and save it, as shown below.
Now you can try using edge-tts
for speech synthesis.
Billed based on traffic, it is roughly estimated that 1 RMB can synthesize 3-5 hours of speech (retries due to errors will increase the cost, please test the actual cost yourself, this is for reference only).