XML 162 R140.htm IDEA: XBRL DOCUMENT
v3.21.1

Salaries and social security - Summary of detailed information about salaries and social security (Parenthetical) (Detail) $ in Millions | Dec. 31, 2020 ARS ($)
--- | ---
Disclosure Of Salaries And Social Security [Abstract] |
Provision for voluntary retirement plan | $ 6,102

X
- Definition Disclosure of salaries and social security. + References No definition available. + Details
Name: | ypf_DisclosureOfSalariesAndSocialSecurityAbstract
Namespace Prefix: | ypf_
Data Type: | xbrli:stringItemType
Balance Type: | na
Period Type: | duration

X
- Definition Provision for voluntary retirement plan + References No definition available. + Details
Name: | ypf_ProvisionForVoluntaryRetirementPlan
Namespace Prefix: | ypf_
Data Type: | xbrli:monetaryItemType
Balance Type: | credit
Period Type: | instant