Urine potassium levels are typically measured through a urine test. A 24-hour urine collection is considered the most accurate method to assess potassium excretion. In some cases, a random urine sample might be used, but it is generally less reliable.