StayFile · On this deviceStayFile · 文件留在本地
Compress PDF.压缩 PDF。
Re-encode each page as a JPEG at high, medium, or low quality. The original stays put, and text in the download may no longer be selectable.按高、中、低三档把每一页重写成 JPEG。原文件留在原地,下载里的文字可能无法再选中。
This rebuilds every page as a JPEG. Text may stop being selectable. If the new file is worse, keep the original.每一页都会被重写成 JPEG。文字可能无法再选中。如果新文件更差,请保留原件。
How it works它怎么处理
Compress PDF on StayFile makes a smaller file by redrawing every page as a JPEG and building a new PDF around those pictures. The download is named stayfile-compressed.pdf. It is a free page from Haimc (海明创), with no account and no upload. This is not a hidden server optimizer, and it is not a lossless pass that only deletes unused objects. You pick High, Medium, or Low, the tab draws each page, and the browser saves the new file. The original you picked is not replaced.
StayFile 的压缩 PDF 把每一页重绘成 JPEG,再用这些图片做成一份新 PDF,从而得到更小的文件。下载文件名叫 stayfile-compressed.pdf。这是海明创(Haimc)的免费页面,没有账号,也不会上传。这不是藏在服务器上的压缩器,也不是只删掉无用对象的无损处理。你选择高、中或低,标签页把每一页画出来,再由浏览器保存新文件。你选中的原件不会被替换。
Drawing happens in this tab. StayFile reads the PDF with pdf-lib to count the pages, then uses PDF.js to paint each page onto a canvas. The canvas is filled white first, so transparent areas become white. That bitmap is saved as a JPEG, and pdf-lib places the JPEG on a new page that keeps the original page size in points, including the rotation you already see in a viewer. A line under the button names the page being drawn. The first time you compress, the page loads a PDF.js worker, plus font and decoder files, from this same website (/pdfjs/). That request is for the program. It does not include your PDF.
绘制发生在这个标签页里。StayFile 先用 pdf-lib 读 PDF、数页数,再用 PDF.js 把每一页画到画布上。画布会先涂成白色,所以透明区域会变成白色。这张位图存成 JPEG,pdf-lib 再把它放上新的一页。新页面的尺寸(点)保持原样,也包括你在阅读器里已经看到的旋转。按钮下面会写明正在绘制第几页。第一次压缩时,页面会从本站(/pdfjs/)加载 PDF.js 的工作线程,以及字体和解码文件。那个请求要的是程序,里面没有你的 PDF。
The three settings are fixed so the result is predictable. Medium is selected when you open the page. High draws at about 144 pixels per inch with JPEG quality 0.82, for pages where small type still has to be read. Medium uses about 110 pixels per inch and JPEG quality 0.62, the usual choice for a phone scan you want to email. Low uses about 72 pixels per inch and JPEG quality 0.45, a preview copy rather than a print master. You cannot type a target such as “under 2 MB”. Compare the sizes StayFile prints after the run. The long edge of a bitmap is capped at 4096 pixels, so one huge page does not exhaust the tab. On that page the JPEG is still stretched to the original page size, which can look softer than the dpi number suggests.
三档是固定的,结果才好预期。打开页面时选中的是中等。高质量大约 144 像素每英寸,JPEG 质量 0.82,适合还要辨认小字的页面。中等大约 110 像素每英寸,JPEG 质量 0.62,适合准备用邮件发出的手机扫描件。低质量大约 72 像素每英寸,JPEG 质量 0.45,适合预览,不适合作为印刷母版。你不能输入“小于 2 MB”这样的目标。跑完之后,看 StayFile 标出的两个大小。位图长边限制在 4096 像素,避免一页特别大的页面把标签页撑满。那一页上的 JPEG 仍会被铺满原来的页面尺寸,看起来可能比 dpi 数字更软。
What you lose is everything that is not the picture. Vector text becomes pixels. You will not be able to select or search the text in the download, and a scan does not gain a text layer, because there is no OCR step. Links, form fields, bookmarks, attachments, and document info are not copied. A digital signature does not survive as a signature. The picture of a signature may still be visible. Colors are approximate, because JPEG is lossy. If a font was not embedded in the source, the picture can use a fallback font on this device, so the page may not match another PDF viewer on a different computer. The page size you see is preserved. The words on the page do not stay as text.
丢掉的是画面以外的一切。矢量文字会变成像素。下载文件里的文字无法再选中或搜索;扫描件也不会因此多出文字层,因为这里没有 OCR。链接、表单字段、书签、附件和文档信息都不会被复制。数字签名不会作为签名留下来。签名的样子可能还看得见。颜色是近似的,因为 JPEG 有损。如果源文件没有嵌入字体,画面可能会用这台设备上的替代字体,所以和另一台电脑上的阅读器不一定一致。你看到的页面尺寸会保留。页面上的文字不会再作为文字留下来。
Do not use Compress when you still need selectable text, a working form, a valid digital signature, or a print master. Do not use it to remove a password: encrypted PDFs are refused, and StayFile will not unlock them. One file, at most 40 pages, and 80 MB. A longer document is refused up front. Split out a section, compress that section, and repeat. A phone browser can run it, but redrawing is heavier than copying pages, and a long scan can run out of memory. If the new file is larger, or the type is too soft to read, keep the original. The size line under the result is there so you can see that.
如果你还需要能选中的文字、能填写的表单、有效的数字签名,或一份印刷母版,就不要用压缩。也不要用它来去掉密码:加密的 PDF 会被拒绝,StayFile 不会解锁。一次一份文件,最多 40 页,不超过 80 MB。更长的文档会在一开始就被拒绝。请先拆出一段,压缩这一段,再处理下一段。手机浏览器可以跑,但把页面画成图片比复制页面更重,很长的扫描件仍可能把内存用完。如果新文件更大,或者字软得看不清,请留着原件。结果下面的大小对照就是为了让你看见这一点。
Example例子
A 20-page phone scan of receipts is 18 MB because each photo was stored full size. Choose Medium, which is already selected. StayFile draws all 20 pages and shows the original size next to the new size. That kind of photo-heavy scan often drops sharply. Open the download and read a receipt total before you email stayfile-compressed.pdf. The 18 MB original is still the file you picked. Text on the receipts was never real text, so nothing searchable is lost. A digital stamp that was only a picture of a stamp is still a picture.
一份 20 页的收据手机扫描件有 18 MB,是因为每张照片都按原尺寸嵌在里面。选择中等,打开页面时就是这一档。StayFile 会把 20 页都画出来,并在新大小旁边标出原来的大小。这种照片很多的扫描件常常会明显变小。把 stayfile-compressed.pdf 放进邮件之前,先打开下载文件,核对一张收据上的金额。那份 18 MB 的原件仍是你选中的文件。收据上的字本来就不是真正的文字,所以没有可搜索的内容会被丢掉。如果章只是一枚章的照片,它仍然是照片。
A two-page text invoice that is already 80 KB, with selectable line items and an embedded font. High, Medium, and Low can all make a larger file, because a JPEG of a whole page is heavier than the original text instructions. If the new file is larger, the page says so and tells you to keep the original. The type in the download is no longer selectable, and the invoice is no longer a document you can copy a total from. Leave this invoice uncompressed. Compress is the wrong tool for a small text PDF.
一份已经只有 80 KB 的两页文字发票,明细可以选中,字体也嵌在文件里。高、中、低三档都可能让文件变大,因为整页的 JPEG 比原来的文字指令更重。如果新文件更大,页面会说明这一点,并让你留着原件。下载文件里的字无法再选中,你也不能再从发票里复制一个合计。这份发票不要压缩。对本来就很小的文字 PDF,压缩是用错了的工具。
A 60-page signed policy that has to stay searchable for the legal file, plus a 12-page photo appendix the client cannot accept by email. Do not compress the policy. Split the appendix out, then compress those 12 pages at High if the captions are small, or Medium if they are ordinary photos. The policy’s signature, bookmarks, and selectable text stay on the original. The appendix download is a picture: the signature image may still show, but it is not a valid digital signature, and the captions cannot be selected. Send the original policy and the compressed appendix as two files.
一份 60 页、必须保持可搜索的签字制度,外加客户邮件收不了的 12 页照片附录。不要压缩那份制度。先把附录拆出来,小字说明多就用高质量压这 12 页,普通照片就用中等。制度原件上的签名、书签和可选中的文字都留在原件里。附录的下载是图片:签名的样子可能还在,但已经不是有效的数字签名,说明文字也不能再选中。请把制度原件和压缩后的附录分成两个文件发送。
Disclaimer说明
Compress photographs each page. Text may no longer be selectable or searchable, small type can soften, colors are approximate, and a digital signature does not remain a signature. Links, form fields, bookmarks, attachments, and document info are not copied into the new file. Transparent areas are painted white. If the download is larger or less readable than the original, keep the original. Encrypted PDFs are refused. There is no OCR and no target file size.
压缩会把每一页画成图片。文字可能无法再选中或搜索,小字可能变糊,颜色是近似的,数字签名也不会再是签名。链接、表单字段、书签、附件和文档信息都不会进入新文件。透明区域会被涂成白色。如果下载文件比原件更大或更难看清,请保留原件。加密的 PDF 会被拒绝。这里没有 OCR,也不能指定目标文件大小。
One run is one file, at most 40 pages, and 80 MB. The long edge of each bitmap stops at 4096 pixels. A phone can open the page, but redrawing can exhaust a phone on a long scan. PDF.js program files load from this website the first time you compress. Your PDF is not in that request. Closing the tab discards the in-memory copy. It does not delete the original or a download you already saved.
一次一份文件,最多 40 页,不超过 80 MB。每张位图的长边停在 4096 像素。手机可以打开这个页面,但很长的扫描件在重绘时仍可能把手机内存用完。第一次压缩时,PDF.js 的程序文件从本站加载。那个请求里没有你的 PDF。关掉标签页会丢掉内存中的副本。它不会删除原件,也不会删除你已经保存的下载。
FAQ常见问题
Will the text stay selectable?文字还能选中吗?
No. The download is a picture of each page. You cannot select the text, and you cannot search it. There is no OCR, so a scan does not become searchable either. If you need the words later, keep the original. Merge and Split copy pages instead of photographing them, so text survives there. It does not survive here.
不能。下载文件是每一页的图片。文字不能选中,也不能搜索。没有 OCR,扫描件也不会因此变成可搜索的文字。如果以后还需要这些字,请留着原件。合并和拆分是复制页面,不是把页面拍成图片,所以文字在那边还在。在这里则不会留下。
Does this remove a password?这能去掉密码吗?
No. If the PDF is encrypted, the tool stops and tells you. It does not ask a server to unlock it, and it does not ask you for the password. Unlock it in a viewer that already has the password, export a normal PDF, and compress that export if you still want a picture copy.
不能。如果 PDF 已加密,工具会停下来并告诉你。它不会请服务器去解锁,也不会向你要密码。请在已经有密码的阅读器里解锁,导出一份普通 PDF;如果仍想要一份图片副本,再压缩那一份。
Why did the file get bigger?为什么文件变大了?
The source was already compact. Photographing it at the quality you chose made more data, not less. A small text invoice is the usual case. The size line under the result shows the original and the new file, and warns you when the new one is not smaller. Keep the original. Compress helps photo scans more often than it helps text.
源文件本来就很小。按你选的质量把它画成图片,数据可能变多而不是变少。很小的文字发票就是常见的这种情况。结果下面会标出原来的大小和新文件的大小,新文件没有变小时还会提醒你。请留着原件。压缩对照片扫描件往往有用,对文字文件则常常没用。
Are pages sent away to be compressed?页面会被送去压缩吗?
No. Drawing uses the canvas in this tab. PDF.js is loaded from this website, under /pdfjs/, so the page can be drawn. Those files are the program: the worker, character maps, standard fonts, and a decoder. The PDF you picked stays in the tab. The download is saved by your browser as stayfile-compressed.pdf.
不会。绘制用的是这个标签页里的画布。PDF.js 从本站的 /pdfjs/ 加载,是为了把页面画出来。那些文件是程序:工作线程、字符映射、标准字体,以及解码器。你选中的 PDF 留在标签页里。下载由浏览器保存为 stayfile-compressed.pdf。
How many pages can I compress?一次能压缩多少页?
Up to 40, and the file must be 80 MB or smaller. A longer file is refused before drawing starts. Rasterizing is heavier than copying pages. Split out a section of 40 pages or fewer, compress that section, and repeat. There is no batch of many PDFs on this page. One file is open at a time.
最多 40 页,文件不超过 80 MB。更长的文件会在开始绘制之前被拒绝。把页面画成图片比复制页面更重。请先拆出 40 页以内的一段,压缩这一段,再处理下一段。这个页面不能一次丢进很多份 PDF。一次只打开一份。
What do High, Medium, and Low change?高、中、低分别改什么?
Only how finely the page is drawn, and how hard the JPEG is squeezed. High is about 144 dpi and JPEG quality 0.82. Medium, the preset already selected, is about 110 dpi and 0.62. Low is about 72 dpi and 0.45. There is no custom slider and no “make it 2 MB” box. A page whose long edge would pass 4096 pixels is scaled down before the JPEG is made. The PDF page size in points stays the size you already see.
变的只是页面画得有多细,以及 JPEG 压得有多狠。高质量大约 144 dpi,JPEG 质量 0.82。中等是打开时已经选中的那一档,大约 110 dpi、0.62。低质量大约 72 dpi、0.45。没有自定义滑杆,也没有“压到 2 MB”的输入框。长边会超过 4096 像素的页面,会先缩小再做成 JPEG。PDF 的页面尺寸(点)仍是你已经看到的那个尺寸。
What happens to signatures, forms, and links?签名、表单和链接会怎样?
They do not survive as working parts of the PDF. A signature may still be visible as ink in the picture, but it is not a valid digital signature of the new file. Form fields cannot be filled. Links cannot be clicked. Bookmarks and attachments are gone. If any of those have to keep working, keep the original and compress a copy only when a picture is enough.
它们不会作为 PDF 里还能用的部分留下来。签名也许还能在画面里看见墨迹,但已经不是新文件的有效数字签名。表单字段不能再填。链接不能再点。书签和附件都没有了。如果这些还必须能用,请留着原件;只有画面就够的时候,再压缩一份副本。
Can I compress on a phone, and is it free?手机上能压缩吗,收费吗?
It is free, with no account, in the phone’s browser or on a computer. Nothing is uploaded. The phone uses the file picker. Redrawing 40 photo pages can still be too heavy for a phone with little free memory. If the tab stalls, compress fewer pages. StayFile does not install an app and does not replace the original file.
免费,不需要账号,手机浏览器和电脑都可以用。什么都不会上传。手机用文件选择器。把 40 页照片重绘一遍,对剩余内存不多的手机仍可能太重。如果标签页卡住,请少压几页。StayFile 不会安装应用,也不会替换原文件。