Is there an "ideal" ratio of tax revenue to GDP? Or, at least, can I assume a higher ratio is better? At the link below, you can see countries have a huge difference in ratios of tax revenue to GDP. Is it fair to assume that a higher ratio is better? Does raising a substantial portion of your GDP in taxes mean that your country is more or less financially stable? 

I see that Algeria is #1 worldwide at 63%, while UAE is the lowest at 1.4%. I assume this is because the UAE has a huge GDP from oil (and thus taxes don't play a big role in its GDP) and because Algeria has a tiny GDP (and thus, a fairly-efficient tax system results in a fairly high ratio).

https://en.wikipedia.org/wiki/List_of_countries_by_tax_revenue_to_GDP_ratio
There is no ideal ratio as the “ideal” (I choose to interpret the ideal as optimal/efficient) level of tax to GDP depends on the moral philosophy. Generally Ralwsians prefer more taxation in order to help poor people, through redistribution, than libertarians/classical liberals, who would prefer private solutions such as charity.
Higher is not always better. First, there is a Laffer curve - at a 100% tax rate the collected tax is zero because nobody is going to willingly become a slave by working only so that government takes all of their money. So there is always a maximum tax rate and implied tax to GDP ratio that is the maximum feasible tax any rational government can implement. Where exactly is the peak (gov revenue maximizing) tax rate changes from country to country, although in advanced countries it is usually around 60-70% (see for example this study) of all income meaning tax to GDP ratio would be 0.6-0.7.
Second, actually the peak of Laffer curve is higher than a welfare maximizing top marginal rate even under Ralwsian preferences (which are the most commonly used redistribute preferences) so if you care about welfare of population instead of just the revenue of government you would usually keep the tax to GDP ratio lower.
Country can be financially stable at any tax to GDP ratio. In order to be financially stable you just need to have debt to GDP ratio be on non-explosive path. The explosive path is a one where debt grows faster than the overall economy in long run. As long as the debt grows at the same rate as economy or at smaller rate the country’s public finances are stable.
Having high tax to GDP ratio does not mean your tax system is efficient. Algeria is not really known for its tax efficiency.