Legal costs are deductible as liabilities of estate (§ 10 para. 5 no. 3 Inheritance and Gift Tax Act [IGTA]), even if they are not directly related to the acquired assets which are subject to tax.
Costs, which are directly related to the execution, arrangement, or distribution of the deceased’s estate or the obtaining of the acquisition, are also deductible as liabilities of estate. This includes costs
• of opening the will,
• of correcting the land title register entry,
• of tracing the heirs,
• for issuing the certificate of inheritance,
• of the distribution of the deceased’s estate,
• for appealing against the last will,
• of preliminarily securing the deceased’s estate,
• associated with the settlement of liabilities of the estate,
• for lawyers, courts, traveling in relation to the regulation of the deceased’s estate and its distribution,
• for the determination of the value of the deceased’s estate and establishing an inventory,
• for tax advice,
• of an inheritance dispute, an action for restitution or distribution,
• adequate costs for the execution of a will, depending on the nature and extent of the services and the amount of the deceased’s estate.
For more details see Koeniger, The German Inheritance and Gift Tax, 2017, p. 87 et seqq.