So accountants struggle with this same issue... and I'm pretty sure that most of the one-man, one woman operations just get beat up all the time on their hourly rates...
Here are the ways I encourage fellow tax accountants fix this issue:
1. Regular inflation adjustments... E.g., 5% every year. No matter what. Here's blog post I did a while back that explains how you and I get killed if we don't do this:
https://evergreensmallbusiness.com/please-bump-your-prices-for-inflation/2. Avoid as much as you can billing by the hour...but bill by the job or project. Called "value billing" this approach probably lets you price services so you actually make money. E.g., don't bill $50 or $100 a hour... bill $500 or $1000 or $10000... and then make sure what you deliver is worth more, ideally way more, than the price. (Suggestion: Get a copy of any book written by Ron Baker and learn about the philosophy of "value billing"... using the value billing model will change your business.)
3. Track and be sure you bill (one way or another) for all your hours. People (er, clients and customers) can really easily lose track of how much "free" help they get. But that can just radically, radically cut the hours you actually have to sell. E.g., we've regularly tracked the the hours of "free" customer service we provide and it runs about 50% of the work of a tax return. E.g., if the tax return takes 4 hours, there's usually another 2 hours of follow-on service. If we only bill for 4 hours but work 6, yikes, that really destroys the actual realized hourly rate. $100 an hour goes to $66 an hour.
4. Invest in technology and training that makes you more efficient and more valuable.
5. Get your marketing working well enough that you can filter the low margin clients... (the awkward reality is that really nice clients with problems you'd be a great person to help solve simply can't afford to pay what you need them to pay to make a good living... you need to NOT subsidize these folks businesses or lives giving away time for free or discounting your prices.
6. Never discount your prices. Discounting only works if you have ability to massively scale. And that's never true with a professional service business.
At the end of the day, you should be able to make a good living by doing IT consulting... and if you're not, you need to raise your rates.