Template:Webarchive
Adds a link to an archived copy of a web page, for example on the Internet Archive's Wayback Machine. Use it in External links sections, or after a bare link, when the original page has gone offline. Works without Lua/Scribunto; needs only the ParserFunctions extension.
Inside citations you do not need this template: use |archive-url= and |archive-date= in Template:Cite web or Template:Cite news instead.
Usage
{{Webarchive |url=ARCHIVE URL |date=ARCHIVE DATE |title=TITLE}}
Examples
| Code | Result |
|---|---|
{{Webarchive |url=https://web.archive.org/web/20160101000000/http://example.com/}} |
|
{{Webarchive |url=https://web.archive.org/web/20160101000000/http://example.com/ |title=Example page}} |
|
{{Webarchive |url=https://archive.ph/AbC12 |date=2020-05-03}} |
|
{{Webarchive |url=https://archive.ph/AbC12 |date=2020-05-03 |df=mdy}} |
|
{{Webarchive |url=https://web.archive.org/web/20190715000000/http://example.com/ |url2=https://archive.ph/AbC12 |date2=2021-01-02}} |
Typical use in External links:
== External links ==
* [http://example.com/ Official website] {{Webarchive |url=https://web.archive.org/web/20160101000000/http://example.com/}}
Parameters
| Parameter | Description |
|---|---|
url or 1 |
Required. Full URL of the archived copy. |
date |
Date of the archived copy, e.g. 2020-05-03. For Wayback Machine links the date is read from the URL automatically (the 14-digit number after /web/), so it can be left out. For other archives, add it.
|
title |
Link text. When given, the output is "TITLE at SERVICE (archived DATE)". |
df |
Date format: dmy (default, 3 May 2020), mdy (May 3, 2020) or ymd (2020-05-03).
|
service |
Name of the archive, if the automatic name is wrong. |
url2, date2, url3, date3 |
Optional additional archive copies. |
The archive service is recognised automatically:
| URL starts with | Shown as |
|---|---|
https://web.archive.org / http://web.archive.org |
the Wayback Machine |
https://archive.today, archive.ph, archive.is, archive.li, archive.md |
archive.today |
https://ghostarchive.org |
Ghost Archive |
https://www.webcitation.org |
WebCite |
| anything else | the website name (e.g. example.org) |
If the date cannot be read from a long or unusual Wayback URL, it is simply left out; add |date= to show it.
Pages using the template without a URL are added to the hidden Category:Webarchive template errors.
TemplateData
Link to an archived copy of a web page (Wayback Machine, archive.today, etc.). Use outside citations; inside citations use archive-url and archive-date.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Archive URL | url 1 | Full URL of the archived copy. | URL | required |
| Archive date | date | Date of the archived copy. Optional for Wayback Machine URLs (read from the URL). | Date | suggested |
| Title | title | Link text. | String | optional |
| Date format | df | dmy (default), mdy or ymd.
| Line | optional |
| Archive service name | service | Override the automatic archive name. | Line | optional |
| Second archive URL | url2 | no description | URL | optional |
| Second archive date | date2 | no description | Date | optional |
| Third archive URL | url3 | no description | URL | optional |
| Third archive date | date3 | no description | Date | optional |