Skip to content

Image Upload Mechanism

Learn how Moire handles image uploads and its limitations

Moire supports inserting images into notes, but there are some important limitations to ensure stability.

When you insert an image in Apple Notes and sync:

  1. Shortcut extracts the first image from the note
  2. Converts the image to Base64 encoding
  3. Uploads it to the /src/memos/images/ directory in the GitHub repository
  4. Automatically inserts the image link into the Markdown file

Whenever the Moire Sync Shortcut runs, it will only upload the first image found in the note.

This is to ensure the speed and stability of the Shortcut.

Currently, Moire does not handle the deletion of images automatically.

To prevent the GitHub repository from growing excessively, please be cautious when replacing or deleting images in your posts. If you remove an image link from your note, the previously uploaded image file in /src/memos/images/ will still remain in the repository.

  • Keep it to 1 image per note
  • Use the image as a cover or key visual
  • Keep image size under 1MB
  • Insert multiple images (only the first will upload)
  • Upload oversized images (may cause sync failure)
  • Rely on images for critical information (may load slowly)

Uploaded images are automatically named as:

[file-hash].png

Possible causes:

IssueSolution
Image too largeCompress the image or use a smaller format
Network timeoutCheck your connection and retry the sync
Insufficient Token permissionsEnsure Token has Contents: Read/Write permissions
Unsupported formatUse PNG or JPG

Check:

  • If GitHub Actions built successfully
  • If the image was correctly uploaded to /src/memos/images/
  • If the image path in Markdown is correct

If you need more than one image in a post, here are alternative solutions:

Combine multiple images into one before uploading.

Pro: Only counts as 1 upload
Con: Requires extra tools for processing

  1. Manually upload images to the repository’s /src/memos/images/ directory
  2. Use relative paths to reference them in your note

Pro: Full control
Con: Loses the convenience of the Shortcut

If you are in mainland China, you may need to configure API acceleration.