Better-auth ratelimit vs upstash rate limit

I am wondering if there is any meaningful difference in using https://upstash.com/docs/redis/sdks/ratelimit-ts/gettingstarted vs using better-auth rate limiting with redis as a backend (using redis.get() and redis.set()).

I know that the upstash lib will use an efficient windowing algorithm.

I could use the upstash middleware "upstream" from the better auth route handlers but I am not sure how supported that is.

Anyone else have any thoughts?
Was this page helpful?