In my experience, the golden rule is to keep your bedside table 5 to 10 cm...
https://amumreviews.co.uk/should-bedside-tables-be-higher-than-the-bed/
In my experience, the golden rule is to keep your bedside table 5 to 10 cm below the top of your mattress. This prevents you from knocking things over at night while keeping your water or phone within easy reach