Add Media Files to a Package
mainTo include sounds or images in your deck, you must perform two steps:
- Assign files to the Package: Set the
media_filesattribute on yourPackageinstance with a list of paths (relative or absolute) to the files. - Reference files in Note fields: In your
Notefields, use the specific Anki syntax for media. Use the filename only (basename), not the full path, inside the field value.
Media Syntax:
- Audio:
[sound:filename.mp3] - Images:
<img src="filename.jpg">