SimplePasteImage is an extension which allows to automatically upload images when you copy-paste something on a wiki page in VisualEditor.
MediaWiki page: https://www.mediawiki.org/wiki/Extension:SimplePasteImage
- Allow uploads from external URLs by specifying
$wgAllowCopyUploads = true;inLocalSettings.php - Download and place the file(s) in a directory called SimplePasteImage in your extensions/ folder.
- Add the following code at the bottom of your LocalSettings.php file:
wfLoadExtension( 'SimplePasteImage' ); - Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.
Simple gif to show how it works:

It is a PoC for now. We havea big list to do:
- Check behaviour on re-upload deletd file
- Error reporting
- Wait form
- Test paste when copy from local apps (Word?). Likely we cannot paste images in this case but
- Test older MWs (oldest supproted?). Looks like we can make it very generic (we need ot modify buffer only).
- Enable when pasting one file
- Fix image URLs, make it so image is not a link to its file
- Test what if copy-paste images from VE of the same wiki
- ...
- Ofc refactoring. Currently it is a mess, I wanted to see if the idea works at all
Nevertheless, it works in simple scenarios