The default retention is ~7 years for user data; retention for internal data is far less - as low as 30 days for _internal. Assuming you have not changed those settings, you can retrieve older data by specifying an old date in the time picker or by using earliest.
index=foo earliest=-3y | ...
Of course, this whole discussion (in this and other threads) presumes time is the only retention factor. If you don't have enough storage for 7 years of data then Splunk will delete the oldest buckets to make room for new ones - and the retention period will be reduced.
--- If this reply helps you, an upvote would be appreciated.