Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Slices from Guides + Save for Web (Legacy)” Unusable for Images Over 30,000 Pixels in Height

New Here ,
Aug 15, 2025 Aug 15, 2025

Photoshop Feature Limitation Feedback: “Slices from Guides + Save for Web (Legacy)” Unusable for Images Over 30,000 Pixels in Height

 

Dear Photoshop Product Team,

I’m a long-time Photoshop user working on web and e-commerce imagery. In daily production, the combination of Slices from Guides and Save for Web (Legacy) is one of the most efficient workflows for splitting long images and optimizing page loading:

  • Fast and precise: For a 35,000-pixel-tall image, placing 10 guides produces 11 slices in one pass—accurate and convenient.

  • Better performance on the web: Separate slices can load in parallel, improving page speed and user experience.

  • Aligned with modern platform needs: Long product pages and scrollable content on Amazon, AliExpress, Facebook, Twitter, Weibo, and personal sites frequently exceed 30,000 px in height.

However, Save for Web (Legacy) currently enforces a 30,000-pixel height cap. If an image exceeds this—even by 1 pixel—the feature becomes unusable. This forces an inefficient workaround:

  1. Manually split the original into multiple files;

  2. Re-run Slices from Guides and export for each file;

  3. Endure extra time, higher complexity, and more risk of misaligned slices or naming errors.


Why this limit is outdated

This restriction likely dates back to the CS6 (2012) era, when typical desktops had 4–6 GB RAM and far slower CPUs, making crashes and memory overflow a real concern for very large images. In 2025, mainstream machines commonly have 16–64 GB RAM and CPUs that are orders of magnitude faster, making large-image processing far more stable.


Suggested improvements

  1. Remove the fixed 30,000-pixel height limit for Save for Web (Legacy).

  2. If stability is a concern, apply a dynamic limit based on hardware (e.g., conservative thresholds for 8–16 GB RAM, relaxed or no limit for 32 GB+).

  3. Provide a user-configurable maximum export height, allowing users to tune the limit for their system and workflow.


Why this matters

  • Preserves and strengthens the efficiency of Slices from Guides + Save for Web (Legacy).

  • Meets today’s real-world requirements for ultra-tall images across web and e-commerce.

  • Reduces unnecessary manual splitting, lowers error rates, and saves significant production time.


Conclusion

Save for Web (Legacy) combined with Slices from Guides is a highly valuable workflow, but the 30,000-pixel height cap has become a major bottleneck. I respectfully urge the team to lift or modernize this limit so the feature can fully support current web and e-commerce design needs.

Sincerely,
A dedicated Photoshop user who values and relies on this feature

TOPICS
macOS , Windows
574
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Mentor ,
Aug 15, 2025 Aug 15, 2025

Hi! The Divide my image to layers topic has a script that creates a separate layer from each slice, it has no document size restrictions. In the version at the link, it does not save files. If you specify the requirements for the saving format and how the files should be named, then it is quite easy to rework it to suit your needs. Here is a version that saves slices to psd:

#target photoshop
var s2t = stringIDToTypeID,
    AR = ActionReference,
    AD = ActionDescriptor;
try {
    try {
        (r = new AR).putProperty(s2t('property'), p = s2t('layerID'));
        r.putEnumerated(s2t('layer'), s2t('ordinal'), s2t('targetEnum'));
        var id = executeActionGet(r).getInteger(p);
    }
    catch (e) { throw "No layer selected!\nOpen the document and select layer" }
    try {
        (r = new AR).putProperty(s2t('property'), p = s2t('slices'));
        r.putEnumerated(s2t('document'), s2t('ordinal'), s2t('targetEnum'));
        var slices = executeActionGet(r).getObjectValue(p).getList(p);
    }
    catch (e) { throw "This version of photoshop does not have access to slices" }
    (r = new AR).putProperty(s2t('property'), p = s2t('resolution'));
    r.putEnumerated(s2t('document'), s2t('ordinal'), s2t('targetEnum'));
    var res = executeActionGet(r).getDouble(p);
    (r = new AR).putProperty(s2t('property'), p = s2t('title'));
    r.putEnumerated(s2t('document'), s2t('ordinal'), s2t('targetEnum'));
    var nm = executeActionGet(r).getString(p).replace(/\..+$/, '');
    try {
        (r = new AR).putProperty(s2t('property'), p = s2t('fileReference'));
        r.putEnumerated(s2t('document'), s2t('ordinal'), s2t('targetEnum'));
        var pth = executeActionGet(r).getPath(p);
    }
    catch (e) { throw "File not saved!" }
    for (var i = 0; i < slices.count - 1; i++) {
        (r = new AR).putIdentifier(s2t('layer'), id);
        (d = new AD).putReference(s2t('target'), r);
        executeAction(s2t('select'), d, DialogModes.NO);
        (r = new AR).putProperty(s2t('channel'), s2t('selection'));
        (d = new AD).putReference(s2t('target'), r);
        d.putObject(s2t('to'), s2t('rectangle'),
            function (b, d) {
                for (var i = 0; i < b.count; i++)
                    d.putUnitDouble(k = (b.getKey(i)), s2t('pixelsUnit'), b.getInteger(k))
                return d;
            }(slices.getObjectValue(i).getObjectValue(s2t('bounds')), new AD)
        );
        executeAction(s2t('set'), d, DialogModes.NO);
        try {
            (d = new AD).putString(s2t("copyHint"), "pixels");
            executeAction(s2t("copyEvent"), d, DialogModes.NO);
            (d = new AD).putClass(s2t("mode"), s2t("RGBColorMode"));
            d.putUnitDouble(s2t("width"), s2t("distanceUnit"), 1 * 72 / res);
            d.putUnitDouble(s2t("height"), s2t("distanceUnit"), 1 * 72 / res);
            d.putUnitDouble(s2t("resolution"), s2t("densityUnit"), res);
            d.putEnumerated(s2t("fill"), s2t("fill"), s2t("white"));
            d.putInteger(s2t("depth"), 8);
            d.putString(s2t("profile"), "sRGB IEC61966-2.1");
            (d1 = new AD).putObject(s2t("new"), s2t("document"), d);
            executeAction(s2t("make"), d1, DialogModes.NO);
            (d = new AD).putEnumerated(s2t("antiAlias"), s2t("antiAliasType"), s2t("antiAliasNone"));
            d.putClass(s2t("as"), s2t("pixel"));
            executeAction(s2t("paste"), d, DialogModes.NO);
            executeAction(s2t("revealAll"), new AD, DialogModes.NO);
            executeAction(s2t("flattenImage"), undefined, DialogModes.NO);
            (d = new AD).putObject(s2t("as"), s2t("photoshop35Format"), new AD);
            d.putPath(s2t("in"), File(pth.path + '/' + nm + ' ' + ('0' + i).slice(-2) + '.psd'));
            executeAction(s2t("save"), d, DialogModes.NO);
            executeAction(s2t("close"), new AD, DialogModes.NO);
            (r = new AR).putProperty(s2t('channel'), s2t('selection'));
            (d = new AD).putReference(s2t('null'), r);
            d.putEnumerated(s2t('to'), s2t('ordinal'), s2t('none'));
            executeAction(s2t('set'), d, DialogModes.NO);
        }
        catch (e) { throw e + "\nScript cannot create layer from empty space!\nMake sure that current layer contains pixels in all slices." }
    }
} catch (e) { alert(e) }

* you can find out more about how to install scripts: Downloading and Installing Adobe Scripts by @Stephen Marsh

 
 

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 15, 2025 Aug 15, 2025
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 16, 2025 Aug 16, 2025

Acknowledgment
I would like to sincerely thank you for sharing your original script, which gave me great inspiration. Based on the idea you provided, I was able to further refine and improve the workflow. Without your initial guidance, this optimized version would not have been possible.

Why I’m Sharing
I’m sharing this improved script here to help other users who face the same limitations when working with very tall images (e.g., e-commerce detail pages, Twitter, AliExpress, Amazon, Weibo, Facebook, etc.). Hopefully, it can make the slicing and exporting process easier and more efficient for those with similar needs.

Hope for Photoshop Improvement
At the same time, I also hope the Photoshop team will consider removing or raising the current 30,000px height limit in “Save for Web (Legacy)” in future versions. Today’s hardware can handle it without issues, and lifting the restriction would make Photoshop even more powerful and user-friendly for modern design workflows.

 

 

 

 

// Photoshop Script: Slice and Export Images Based on Guides
// Functionality:
// 1. Automatically slice the document using existing guides.
// 2. Export each slice as a JPG with maximum quality (12).
// 3. Save the exported files inside a folder named after the document.
// 4. If the folder already exists, automatically create a new one with suffix "--01", "--02", etc.
// 5. File naming format: DocumentName_01, DocumentName_02 ...
// 6. Optionally close the document after exporting to save workflow time.

#target photoshop

(function () {
// ===== CONFIGURABLE PARAMETERS =====
var exportQuality = 12; // JPG export quality (1-12, max = 12)
var autoClose = true; // If true, automatically close the document after slicing

// ===== MAIN SCRIPT =====
if (app.documents.length === 0) {
alert("No open document found.");
return;
}

var doc = app.activeDocument;
var docName = decodeURI(doc.name).replace(/\.[^\.]+$/, ""); // Get document name without extension

// Get parent folder of the PSD
var parentFolder = Folder(doc.path);

// Create output folder with document name
var outputFolder = new Folder(parentFolder + "/" + docName);
var count = 1;
while (outputFolder.exists) {
// If folder exists, create a new one with suffix "--01", "--02"...
var suffix = ("0" + count).slice(-2); // Ensure two digits
outputFolder = new Folder(parentFolder + "/" + docName + "--" + suffix);
count++;
}
outputFolder.create();

// Create slices from guides
doc.slices.removeAll();
doc.slices.fromGuides();

// Export each slice
for (var i = 0; i < doc.slices.length; i++) {
var slice = doc.slices[i];
var sliceName = docName + "_" + ("0" + (i + 1)).slice(-2) + ".jpg";
var file = new File(outputFolder + "/" + sliceName);

var opts = new ExportOptionsSaveForWeb();
opts.format = SaveDocumentType.JPEG;
opts.includeProfile = false;
opts.interlaced = false;
opts.optimized = true;
opts.quality = exportQuality;

doc.exportDocument(file, ExportType.SAVEFORWEB, opts);
}

// Close document after export if enabled
if (autoClose) {
doc.close(SaveOptions.DONOTSAVECHANGES);
}
})();

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Mentor ,
Aug 16, 2025 Aug 16, 2025

is your code generated by LLM? 🤔


try this:

#target photoshop
const exportQuality = 100,
    autoClose = true;
var apl = new AM('application'),
    doc = new AM('document'),
    lr = new AM('layer');
doForcedProgress('', 'main()')
function main() {
    try {
        if (apl.getKey('numberOfDocuments')) {
            var initState = activeDocument.activeHistoryState;
            if (activeDocument.guides.length) doc.slicesFromGuides();
            if (doc.hasKey('slices')) {
                var slices = doc.getKey('slices').value.getList(stringIDToTypeID('slices'));
                if (slices.count > 1) {
                    var selection = [];
                    for (var i = 0; i < slices.count - 1; i++) selection.push(slices.getObjectValue(i).getObjectValue(stringIDToTypeID('bounds')));
                    doc.clearGuides();
                    doc.clearSlices();
                    selection.reverse();
                    var len = selection.length,
                        digits = len > 0 && len <= 9 ? 2 : (String(len)).length,
                        h = activeDocument.activeHistoryState,
                        title = doc.getKey('title').replace(/\.[^\.]+$/, ''),
                        pth = getUniqueFolderPath(doc.getKey('fileReference').path, title),
                        options = function () { var o = new ExportOptionsSaveForWeb(); o.format = SaveDocumentType.JPEG; o.includeProfile = false; o.interlaced = false; o.optimized = false; o.quality = exportQuality; return o }();
                    for (var i = 0; i < len; i++) {
                        changeProgressText('Export slices: ' + (i + 1) + '/' + len)
                        doc.makeSelection(selection[i]);
                        doc.crop();
                        activeDocument.exportDocument(File(pth + '/' + title + '_' + (('0000' + (i + 1)).slice(-digits)) + '.jpg'), ExportType.SAVEFORWEB, options)
                        activeDocument.activeHistoryState = h;
                    }
                    activeDocument.activeHistoryState = initState;
                    if (autoClose) activeDocument.close(SaveOptions.DONOTSAVECHANGES);
                } else throw new Error('Slices or guides not found in current document!');
            } else throw new Error('This version of Photoshop does not have access to slices');
        } else throw new Error('No opened documents!');
    } catch (e) { alert(e) }
    function getUniqueFolderPath(pth, folderName) {
        var fullPath = new Folder(pth + '/' + folderName);
        if (!fullPath.exists) { fullPath.create(); return fullPath; }
        var i = 1;
        while (true) {
            var suffix = (i < 10) ? '--0' + i : '--' + i;
            fullPath = new Folder(pth + '/' + folderName + suffix);
            if (!fullPath.exists) { fullPath.create(); return fullPath; }
            i++;
        }
    }
}
function AM(target) {
    var s2t = stringIDToTypeID,
        t2s = typeIDToStringID;
    target = target ? s2t(target) : null;
    this.getKey = function (property, id, idxMode) {
        property = s2t(property);
        (r = new ActionReference()).putProperty(s2t('property'), property);
        id != undefined ? (idxMode ? r.putIndex(target, id) : r.putIdentifier(target, id)) :
            r.putEnumerated(target, s2t('ordinal'), s2t('targetEnum'));
        return getDescValue(executeActionGet(r), property)
    }
    this.hasKey = function (property, id, idxMode) {
        property = s2t(property);
        (r = new ActionReference()).putProperty(s2t('property'), property);
        id ? (idxMode ? r.putIndex(target, id) : r.putIdentifier(target, id))
            : r.putEnumerated(target, s2t('ordinal'), s2t('targetEnum'));
        return executeActionGet(r).hasKey(property)
    }
    this.clearSlices = function () {
        (r = new ActionReference()).putEnumerated(s2t('slice'), s2t('ordinal'), s2t('allEnum'));
        (d = new ActionDescriptor()).putReference(s2t('target'), r);
        executeAction(s2t('delete'), d, DialogModes.NO);
    }
    this.clearGuides = function () {
        executeAction(s2t('clearAllGuides'), undefined, DialogModes.NO);
    }
    this.slicesFromGuides = function () {
        (r = new ActionReference()).putClass(s2t('slice'));
        (d = new ActionDescriptor()).putReference(s2t('target'), r);
        d.putClass(s2t('using'), s2t('guides'));
        executeAction(s2t('make'), d, DialogModes.NO);
    }
    this.makeSelection = function (bounds) {
        (r = new ActionReference()).putProperty(s2t('channel'), s2t('selection'));
        (d = new ActionDescriptor()).putReference(s2t('null'), r);
        (d1 = new ActionDescriptor()).putUnitDouble(s2t('top'), s2t('pixelsUnit'), bounds.getDouble(s2t('top')));
        d1.putUnitDouble(s2t('left'), s2t('pixelsUnit'), bounds.getDouble(s2t('left')));
        d1.putUnitDouble(s2t('bottom'), s2t('pixelsUnit'), bounds.getDouble(s2t('bottom')));
        d1.putUnitDouble(s2t('right'), s2t('pixelsUnit'), bounds.getDouble(s2t('right')));
        d.putObject(s2t('to'), s2t('rectangle'), d1);
        executeAction(s2t('set'), d, DialogModes.NO);
    }
    this.crop = function () {
        (d = new ActionDescriptor()).putBoolean(s2t('delete'), true);
        executeAction(s2t('crop'), d, DialogModes.NO);
    }
    function getDescValue(d, p) {
        switch (d.getType(p)) {
            case DescValueType.OBJECTTYPE: return { type: t2s(d.getObjectType(p)), value: d.getObjectValue(p) };
            case DescValueType.LISTTYPE: return d.getList(p);
            case DescValueType.REFERENCETYPE: return d.getReference(p);
            case DescValueType.BOOLEANTYPE: return d.getBoolean(p);
            case DescValueType.STRINGTYPE: return d.getString(p);
            case DescValueType.INTEGERTYPE: return d.getInteger(p);
            case DescValueType.LARGEINTEGERTYPE: return d.getLargeInteger(p);
            case DescValueType.DOUBLETYPE: return d.getDouble(p);
            case DescValueType.ALIASTYPE: return d.getPath(p);
            case DescValueType.CLASSTYPE: return d.getClass(p);
            case DescValueType.UNITDOUBLE: return (d.getUnitDoubleValue(p));
            case DescValueType.ENUMERATEDTYPE: return { type: t2s(d.getEnumerationType(p)), value: t2s(d.getEnumerationValue(p)) };
            default: break;
        };
    }
}

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 16, 2025 Aug 16, 2025
quote

I also hope the Photoshop team will consider removing or raising the current 30,000px height limit in “Save for Web (Legacy)” in future versions

By @??520

 

Save for Web was originally part of ImageReady, released 26 years ago in 1998. It became part of Photoshop with CS3 in 2007. It was intended for breaking images into individual files so the various parts could be optimized separately. It also provided HTML code so that the multiple images could be put into a table and appeared to be one composite image. Web protocol moved on and Save for Web became essentially obsolete.

 

Adobe has not (yet) removed Save for Web from Photoshop, but added the word "Legacy" and told us they would never be updating it.

 

Your post is in Ideas, so the Photoshop Team will see it whether or not they comment, and other users can vote on it if they agree with you.

 

Jane

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Aug 17, 2025 Aug 17, 2025
LATEST

Thank you so much for your help. Your suggestion gave me a completely new perspective, and it allowed me to finally solve a problem that had been troubling me for many years. It has saved me a lot of trouble and brought me great relief. I truly appreciate your patience and generosity in sharing your thoughts with me. Without your support, I might still be stuck. I’m very grateful, and I hope I can return the favor someday.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines