# (Squarespace) Show Images in Gallery in same line

**URL:** <https://community.elfsight.com/t/squarespace-show-images-in-gallery-in-same-line/103907>\
**Category:** Platform Tips\
**Tags:** squarespace\
**Created:** [February 27, 2025, 4:15am UTC](https://community.elfsight.com/t/squarespace-show-images-in-gallery-in-same-line/103907 "2025-02-27T04:15:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![tuanphan](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/tuanphan/32/3165_2.png) [@tuanphan](https://community.elfsight.com/u/tuanphan)\
**Post date:** [February 27, 2025, 4:15am UTC](https://community.elfsight.com/t/squarespace-show-images-in-gallery-in-same-line/103907/1 "2025-02-27T04:15:23Z")

</div>

To make Images in Gallery in the Same Line, you can follow these.

**#1.** First, [find Gallery Section ID](https://community.elfsight.com/t/how-to-find-id-in-squarespace/65340).

In my example, it is: section[data-section-id=”67bd2229d6865e7a07a5a703″]

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/8/1/81456155241422d2d190b1f1cf43cdcb21b4aa3e.jpeg)

**#2**. Next, use this code to Custom CSS

```auto
section[data-section-id="67bd2229d6865e7a07a5a703"] .gallery-grid-wrapper {
    grid-template-columns:repeat(8,1fr) !important;
    grid-gap: 0px 0px !important;
}

```

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/b/e/be986ee45c6435a2daa47dff9c514db60d1cc1f9.png)

Note: If Gallery has 8 images, use number 8 in the code. If the Gallery has 20 images, use number 20.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/9/f/9f8745d2ca09c52d0d2f8e3b0bcbf5f5d1ddbb84.png)

Result

![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/d/9/d909ca73fbebe8294ea6673e6170fd59396d9955.png)

**#3.** If you want to apply this on mobile only, use this CSS code.

```auto
@media screen and (max-width:767px) {
section[data-section-id="67bd2229d6865e7a07a5a703"] .gallery-grid-wrapper {
    grid-template-columns:repeat(8,1fr) !important;
    grid-gap: 0px 0px !important;
}
}

```

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/0/2/02134aceb23a0e123efceb1f5e7524c17e118532.png)

Result

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/6/6/6630f41ab18a40817ae608e4c0e2160c401a8f5d.png)

**#4.** If you want to make it on Desktop only, use this CSS code

```auto
@media screen and (min-width:768px) {
id="67bd2229d6865e7a07a5a703"] .gallery-grid-wrapper {
    grid-template-columns:repeat(8,1fr) !important;
    grid-gap: 0px 0px !important;
}}

```

 ![image](https://us1.discourse-cdn.com/flex020/uploads/elfsight/original/3X/2/0/20a2eb59c7e336ce770bc8b8857e853c4a83a5f8.png)

---

<div class="post-metadata">

**Author:** ![romano97002](https://sea2.discourse-cdn.com/flex020/user_avatar/community.elfsight.com/romano97002/32/95751_2.png) [@romano97002](https://community.elfsight.com/u/romano97002)\
**Post date:** [February 28, 2025, 4:21pm UTC](https://community.elfsight.com/t/squarespace-show-images-in-gallery-in-same-line/103907/2 "2025-02-28T16:21:18Z")

</div>

@tuanphan,

❤ ❤ ❤
