Usually around the holiday season, Walmart sells some of their Hyper ebikes for under $500. Basically a bike with a small battery that will ride 12-16 mph for 20-25 miles, If you know how to tune shifters.brakes, it can be a smooth riding bike. If you cannot, then you'll have a nightmare of bike shops overcharges and snobbish bike owners laughing at you, when all it takes is a couple of screws adjusted.
Cheaper bikes will have crude pedal response. Crude is a relative term, but compared to better bikes, cheap bikes have overboosted response, and it is difficult to ride them slow, especially the model with only 3 assist levels, . They want to go 13-15 mph in level 1, While you can get used to that, instead look for a bike that has an LCD display and 5 levels of assist. The 5 levels will usually give you enough granularity in assist levels that the lower ones will work, If you're hands on, it's no big thing to keep a inexpensive ebike mechanically tuned and running well. If you can't do that, then it's bike shops and making appointments and dropping money on repair bills.
Batteries will probably wear out in 2 years too. Best to buy a bike with an easily replaceable battery. As it turns out, most low cost bikes pull their batteries out of a big bin in China, and it's just a matter of identifying which one in the bin to buy.