According to section 9.16 of the APA manual, 7th edition, you only need to add “retrieved from” and a retrieval date in a reference entry for web sources designed to be continuously updated. For example, an online reference entry from a dictionary or encyclopedia, or a social media page. Including a retrieval date signals to readers that the source may differ in content if retrieved on a different date. When including the retrieval date, insert it before the URL or DOI at the end of the entry:
Retrieved January 1, 2022, from https://chegg.com
For web sources with stable URLs or DOIs that do not change, do not include a retrieval date. Only include the URL or DOI. Section 9.5 of the APA manual, 7th edition provides information on how to format DOIs (Digital Object Identifiers) and URLs (Uniform Resource Locators). Both DOIs and URLs are to be presented as hyperlinks (use http:// or https:// as the case may be). Since these are presented as hyperlinks that the readers can use to access the content, it is NOT necessary to have the words, “Retrieved from” or “Accessed from” before a DOI or an URL. However, test the resource to ensure the hyperlink works.