I discovered that Okular and the Markdown backend do a pretty good job in rendering markdown to pdf including clickable hyperlinks: Open md file and use File -> Export -> PDF. It would be nice if the output paper format was configurable. On my system it seems to be fixed at A4.
The relevant code is located at https://invent.kde.org/graphics/okular/-/blob/master/core/textdocumentgenerator.cpp#L489-499. Currently only QPrinter::setOutputFormat() is called; QPrinter::setPageSize() needs to be added for this to work.